Skip to content

feat: expose radius to config - #798

Open
magnus-rattlehead wants to merge 1 commit into
MalpenZibo:mainfrom
magnus-rattlehead:feat/radius-config
Open

feat: expose radius to config#798
magnus-rattlehead wants to merge 1 commit into
MalpenZibo:mainfrom
magnus-rattlehead:feat/radius-config

Conversation

@magnus-rattlehead

Copy link
Copy Markdown

Wanted to expose the radius options to config, personally I prefer no rounded corners

@romanstingler

Copy link
Copy Markdown
Collaborator

let's wait for
@MalpenZibo 's opinion

from a technical standpoint, add validation rejecting negative radius values via a custom deserializer like opacity_deserializer.
Add [appearance.radius] to the example config in docs/src/core/config-system.md (pre-existing).

[appearance.radius]
sm = 4.0
md = 8.0
lg = 16.0
xl = 32.0

also @MalpenZibo stylisitc question
Field-level #[serde(default)] could be used instead of struct-level. Struct-level #[serde(default)] is fine and more concise, but the rest of Appearance uses field-level attrs (e.g. pub menu: MenuAppearance relies on MenuAppearance's own Default). Either style is acceptable here since Radius has a Default impl

@MalpenZibo

Copy link
Copy Markdown
Owner

Yes, I need to work on this since the last release. I had to decide the right direction. I prefer to work on this stuff personally, so I'm not sure if I will merge this PR. For sure, I will take this into consideration when defining the new option that I plan to add.

#615

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants