Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(action-buttons): add fluent styles
- Loading branch information
Showing
10 changed files
with
129 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
@use "_variables.scss" as *; | ||
|
||
@mixin kendo-action-buttons--layout() { | ||
.k-actions { | ||
padding-inline: var( --kendo-actions-padding-x, #{$kendo-actions-padding-x} ); | ||
padding-block: var( --kendo-actions-padding-y, #{$kendo-actions-padding-y} ); | ||
box-sizing: border-box; | ||
border-width: var( --kendo-actions-border-width, #{$kendo-actions-border-width} ) 0 0 0; | ||
border-style: solid; | ||
border-color: inherit; | ||
flex-shrink: 0; | ||
display: flex; | ||
flex-flow: row nowrap; | ||
align-items: center; | ||
gap: var( --kendo-actions-button-spacing, #{$kendo-actions-button-spacing} ); | ||
overflow: hidden; | ||
|
||
*, | ||
*::before, | ||
*::after { | ||
box-sizing: border-box; | ||
} | ||
} | ||
|
||
// Aliases | ||
.k-edit-buttons, | ||
.k-action-buttons, | ||
.k-columnmenu-actions { | ||
@extend .k-actions; | ||
} | ||
|
||
// Actions align | ||
.k-actions-start { | ||
justify-content: flex-start; | ||
} | ||
.k-actions-center { | ||
justify-content: center; | ||
} | ||
.k-actions-end { | ||
justify-content: flex-end; | ||
} | ||
.k-actions-stretched > * { | ||
flex: 1 0 0%; | ||
} | ||
|
||
// Actions orientation | ||
.k-actions-horizontal { | ||
width: 100%; | ||
flex-flow: row nowrap; | ||
} | ||
.k-actions-vertical { | ||
flex-flow: column nowrap; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
@use "../core/mixins" as *; | ||
@use "_variables.scss" as *; | ||
|
||
@mixin kendo-action-buttons--theme() { | ||
|
||
.k-actions { | ||
@include fill( | ||
var( --kendo-actions-text, #{$kendo-actions-text} ), | ||
var( --kendo-actions-bg, #{$kendo-actions-bg} ), | ||
var( --kendo-actions-border, #{$kendo-actions-border} ) | ||
); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
@use "../core" as *; | ||
|
||
/// Horizontal padding of the action buttons container. | ||
/// @group action-buttons | ||
$kendo-actions-padding-x: map-get( $kendo-spacing, 3 ) !default; | ||
/// Vertical padding of the action buttons container. | ||
/// @group action-buttons | ||
$kendo-actions-padding-y: map-get( $kendo-spacing, 3 ) !default; | ||
/// Width of the border around the action buttons container. | ||
/// @group action-buttons | ||
$kendo-actions-border-width: 0px !default; | ||
/// The background color of the action buttons container. | ||
/// @group action-buttons | ||
$kendo-actions-bg: null !default; | ||
/// The text color of the action buttons container. | ||
/// @group action-buttons | ||
$kendo-actions-text: null !default; | ||
/// The border color of the action buttons container. | ||
/// @group action-buttons | ||
$kendo-actions-border: null !default; | ||
|
||
/// Spacing between the action buttons. | ||
/// @group button | ||
$kendo-actions-button-spacing: map-get( $kendo-spacing, 2 ) !default; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
// Module meta | ||
$_kendo-module-meta: ( | ||
name: "action-buttons", | ||
dependencies: ( | ||
"button", | ||
"icons" | ||
) | ||
); | ||
|
||
|
||
// Component | ||
@forward "_variables.scss"; | ||
@use "_layout.scss" as *; | ||
@use "_theme.scss" as *; | ||
|
||
// Register | ||
@use "../core/module-system" as module; | ||
@include module.register( $_kendo-module-meta... ); | ||
|
||
// Expose | ||
@mixin styles() { | ||
@include module.render( "action-buttons" ) { | ||
@include kendo-action-buttons--layout(); | ||
@include kendo-action-buttons--theme(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters