-
-
Notifications
You must be signed in to change notification settings - Fork 533
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bar: working on new scss #5013
base: master
Are you sure you want to change the base?
Bar: working on new scss #5013
Changes from all commits
344734c
7a64f53
3a5b5d6
2cc810a
b9c3e23
49f2c6e
db323a8
f2fa237
7a781ed
58ad4b4
4f0f74a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -659,21 +659,21 @@ public override string Container( Breakpoint breakpoint ) | |
|
||
public override string Bar( BarMode mode ) => "navbar"; | ||
|
||
public override string BarInitial( BarMode mode, bool initial ) => initial ? "b-bar-initial" : null; | ||
public override string BarInitial( BarMode mode, bool initial ) => initial ? "navbar-initial" : null; | ||
|
||
public override string BarAlignment( BarMode mode, Alignment alignment ) => FlexAlignment( alignment ); | ||
|
||
public override string BarThemeContrast( BarMode mode, ThemeContrast themeContrast ) => $"navbar-{ToThemeContrast( themeContrast )} b-bar-{ToThemeContrast( themeContrast )}"; | ||
|
||
public override string BarBreakpoint( BarMode mode, Breakpoint breakpoint ) => breakpoint != Breakpoint.None && breakpoint != Breakpoint.Mobile ? $"navbar-expand-{ToBreakpoint( breakpoint )}" : null; | ||
|
||
public override string BarMode( BarMode mode ) => $"b-bar-{ToBarMode( mode )}"; | ||
public override string BarMode( BarMode mode ) => mode != Blazorise.BarMode.Horizontal ? $"navbar-{ToBarMode( mode )} flex-column" : null; | ||
|
||
public override string BarItem( BarMode mode, bool hasDropdown ) => mode == Blazorise.BarMode.Horizontal | ||
? hasDropdown | ||
? "nav-item dropdown" | ||
: "nav-item" | ||
: "b-bar-item"; | ||
: "nav-item"; | ||
|
||
public override string BarItemActive( BarMode mode ) => Active(); | ||
|
||
|
@@ -683,55 +683,55 @@ public override string BarItem( BarMode mode, bool hasDropdown ) => mode == Blaz | |
|
||
public override string BarItemHasDropdownShow( BarMode mode ) => null; | ||
|
||
public override string BarLink( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "nav-link" : "b-bar-link"; | ||
public override string BarLink( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "nav-link" : "nav-link"; | ||
|
||
public override string BarLinkDisabled( BarMode mode ) => Disabled(); | ||
|
||
public override string BarBrand( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "navbar-brand" : "b-bar-brand"; | ||
public override string BarBrand( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "navbar-brand" : "navbar-brand"; | ||
|
||
public override string BarToggler( BarMode mode, BarTogglerMode togglerMode ) => mode == Blazorise.BarMode.Horizontal ? "navbar-toggler" : | ||
togglerMode == BarTogglerMode.Popout ? "b-bar-toggler-popout" : "b-bar-toggler-inline"; | ||
togglerMode == BarTogglerMode.Popout ? "navbar-toggler-popout" : "navbar-toggler-inline"; | ||
|
||
public override string BarTogglerCollapsed( BarMode mode, BarTogglerMode togglerMode, bool isShow ) => isShow || mode != Blazorise.BarMode.Horizontal ? null : "collapsed"; | ||
|
||
public override string BarMenu( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "collapse navbar-collapse" : "b-bar-menu"; | ||
public override string BarMenu( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "collapse navbar-collapse" : "collapse navbar-collapse"; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What's the difference here? We have a condition where both cases takes us to the same result? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is it expected to be |
||
|
||
public override string BarMenuShow( BarMode mode ) => Show(); | ||
|
||
public override string BarStart( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "navbar-nav me-auto" : "b-bar-start"; | ||
public override string BarStart( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "navbar-nav me-auto" : "navbar-start flex-column"; | ||
|
||
public override string BarEnd( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "navbar-nav ms-auto" : "b-bar-end"; | ||
public override string BarEnd( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "navbar-nav ms-auto" : "navbar-end flex-column"; | ||
|
||
public override string BarDropdown( BarMode mode, bool isBarDropDownSubmenu ) => mode == Blazorise.BarMode.Horizontal ? "dropdown" : "b-bar-dropdown"; | ||
public override string BarDropdown( BarMode mode, bool isBarDropDownSubmenu ) => mode == Blazorise.BarMode.Horizontal ? "dropdown" : "dropdown"; | ||
|
||
Comment on lines
-705
to
706
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. redundant condition? |
||
public override string BarDropdownShow( BarMode mode ) => Show(); | ||
|
||
public override string BarDropdownToggle( BarMode mode, bool isBarDropDownSubmenu ) => mode == Blazorise.BarMode.Horizontal | ||
? isBarDropDownSubmenu | ||
? "dropdown-item" | ||
: "nav-link dropdown-toggle" | ||
: "b-bar-link b-bar-dropdown-toggle"; | ||
: "nav-link dropdown-toggle"; | ||
Comment on lines
709
to
+713
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please check, but this seems like it can be simplified to |
||
|
||
public override string BarDropdownToggleDisabled( BarMode mode, bool isBarDropDownSubmenu, bool disabled ) | ||
=> mode == Blazorise.BarMode.Horizontal && disabled ? "disabled" : null; | ||
|
||
public override string BarDropdownItem( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "dropdown-item" : "b-bar-dropdown-item"; | ||
public override string BarDropdownItem( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "dropdown-item" : "dropdown-item"; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. redundant? |
||
|
||
public override string BarTogglerIcon( BarMode mode ) => "navbar-toggler-icon"; | ||
|
||
public override string BarDropdownDivider( BarMode mode ) => "dropdown-divider"; | ||
|
||
public override string BarDropdownMenu( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "dropdown-menu" : "b-bar-dropdown-menu"; | ||
public override string BarDropdownMenu( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "dropdown-menu" : "dropdown-menu"; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. redundant? |
||
|
||
public override string BarDropdownMenuVisible( BarMode mode, bool visible ) => visible ? Show() : null; | ||
|
||
public override string BarDropdownMenuRight( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "dropdown-menu-end" : "b-bar-right"; | ||
public override string BarDropdownMenuRight( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? "dropdown-menu-end" : "dropdown-menu-end"; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. redundant? |
||
|
||
public override string BarDropdownMenuContainer( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? null : "b-bar-dropdown-menu-container"; | ||
public override string BarDropdownMenuContainer( BarMode mode ) => mode == Blazorise.BarMode.Horizontal ? null : "dropdown-menu-container"; | ||
|
||
public override string BarCollapsed( BarMode mode ) => null; | ||
|
||
public override string BarLabel( BarMode mode ) => "b-bar-label"; | ||
public override string BarLabel( BarMode mode ) => "navbar-label"; | ||
|
||
#endregion | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not an issue, but I think it reads better in the positive
mode == Blazorise.BarMode.Horizontal
and invert acorrdingly.Also that's how It is done in other places below, so I'd just keep it consistent