@fest-lib/fl-ui 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +3 -0
- package/dist/assets/OPFS.uniform.worker-Ddx6J_37.js +2982 -0
- package/dist/fl-ui.js +16004 -0
- package/dist/font-registry-BWosB92f.js +271 -0
- package/package.json +104 -0
- package/src/styles/font-loader.ts +224 -0
- package/src/styles/font-registry.ts +275 -0
- package/src/styles/fonts/_index.scss +8 -0
- package/src/styles/fonts/_inter.scss +171 -0
- package/src/styles/index.scss +2 -0
- package/src/styles/index.ts +33 -0
- package/src/styles/layers.scss +1 -0
- package/src/styles/patch-global-native-controls.scss +13 -0
- package/src/styles/scripts/encode-fonts.ts +172 -0
- package/src/styles/skins/thin/Thin.ts +13 -0
- package/src/styles/ui/_bar.scss +271 -0
- package/src/styles/ui/_buttons.scss +215 -0
- package/src/styles/ui/_color.scss +3 -0
- package/src/styles/ui/_colorize.scss +5 -0
- package/src/styles/ui/_content.scss +169 -0
- package/src/styles/ui/_essentials-options.scss +2 -0
- package/src/styles/ui/_essentials.scss +705 -0
- package/src/styles/ui/_explorer-content.scss +362 -0
- package/src/styles/ui/_explorer.scss +237 -0
- package/src/styles/ui/_forms-bare-host-elements.scss +25 -0
- package/src/styles/ui/_forms-options.scss +2 -0
- package/src/styles/ui/_forms.scss +280 -0
- package/src/styles/ui/_forms_misc.scss +201 -0
- package/src/styles/ui/_gridbox.scss +298 -0
- package/src/styles/ui/_home-host.scss +179 -0
- package/src/styles/ui/_index.scss +22 -0
- package/src/styles/ui/_launcher-typography.scss +31 -0
- package/src/styles/ui/_layers.scss +48 -0
- package/src/styles/ui/_layout.scss +3 -0
- package/src/styles/ui/_markdown.scss +1636 -0
- package/src/styles/ui/_modal.scss +258 -0
- package/src/styles/ui/_motion.scss +3 -0
- package/src/styles/ui/_native-host-button-chrome.scss +31 -0
- package/src/styles/ui/_orientation-functions.scss +274 -0
- package/src/styles/ui/_orientbox.scss +97 -0
- package/src/styles/ui/_scrollbar.scss +257 -0
- package/src/styles/ui/_shared-overlays.scss +16 -0
- package/src/styles/ui/_sidebar.scss +477 -0
- package/src/styles/ui/_speed-dial.scss +47 -0
- package/src/styles/ui/_tables.scss +28 -0
- package/src/styles/ui/_tabs.scss +406 -0
- package/src/styles/ui/_taskbar.scss +215 -0
- package/src/styles/ui/_toolbars.scss +165 -0
- package/src/styles/ui/_typography.scss +11 -0
- package/src/styles/ui/_utils.scss +8 -0
- package/src/styles/ui/_variables.scss +45 -0
- package/src/styles/ui/_viewport.scss +469 -0
- package/src/styles/ui/_window-frame.scss +658 -0
- package/src/styles/ui/home-host-apply.scss +10 -0
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
@use "sass:map";
|
|
2
|
+
|
|
3
|
+
//
|
|
4
|
+
@use "./layout" as layout;
|
|
5
|
+
@use "./typography" as text;
|
|
6
|
+
@use "./color" as color;
|
|
7
|
+
@use "./colorize" as colorize;
|
|
8
|
+
@use "./motion" as motion;
|
|
9
|
+
@use "./utils" as utils;
|
|
10
|
+
@use "./shared-overlays" as overlays;
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
// -----------------------------------------------------------------------------
|
|
15
|
+
// Shared base styles
|
|
16
|
+
// -----------------------------------------------------------------------------
|
|
17
|
+
|
|
18
|
+
@mixin button-structure() {
|
|
19
|
+
display: inline-flex;
|
|
20
|
+
|
|
21
|
+
//
|
|
22
|
+
place-items: center;
|
|
23
|
+
place-content: center;
|
|
24
|
+
|
|
25
|
+
//
|
|
26
|
+
gap: var(--button-gap, var(--gap-sm));
|
|
27
|
+
|
|
28
|
+
//
|
|
29
|
+
padding-block: var(--button-padding-y, var(--padding-sm));
|
|
30
|
+
padding-inline: var(--button-padding-x, var(--padding-lg));
|
|
31
|
+
min-block-size: var(--button-min-height, fit-content);
|
|
32
|
+
border-radius: var(--button-radius, var(--radius-full));
|
|
33
|
+
|
|
34
|
+
// Cursor and transition
|
|
35
|
+
cursor: pointer;
|
|
36
|
+
transition:
|
|
37
|
+
var(--transition-transform, transform var(--duration-fast) var(--ease-out)),
|
|
38
|
+
var(--transition-colors, color var(--duration-normal) var(--ease-out), background-color var(--duration-normal) var(--ease-out)),
|
|
39
|
+
var(--transition-opacity, opacity var(--duration-normal) var(--ease-out));
|
|
40
|
+
|
|
41
|
+
//
|
|
42
|
+
pointer-events: auto;
|
|
43
|
+
border: none;
|
|
44
|
+
outline: none;
|
|
45
|
+
|
|
46
|
+
//
|
|
47
|
+
position: relative;
|
|
48
|
+
font-size: text.md3-type("label-large", size);
|
|
49
|
+
|
|
50
|
+
//
|
|
51
|
+
letter-spacing: 0.01em;
|
|
52
|
+
text-decoration: none;
|
|
53
|
+
text-overflow: ellipsis;
|
|
54
|
+
white-space: nowrap;
|
|
55
|
+
overflow: hidden;
|
|
56
|
+
user-select: none;
|
|
57
|
+
|
|
58
|
+
//
|
|
59
|
+
min-inline-size: 0px;
|
|
60
|
+
block-size: fit-content;
|
|
61
|
+
inline-size: fit-content;
|
|
62
|
+
max-block-size: stretch;
|
|
63
|
+
max-inline-size: stretch;
|
|
64
|
+
flex-wrap: nowrap;
|
|
65
|
+
|
|
66
|
+
//
|
|
67
|
+
&:disabled {
|
|
68
|
+
opacity: var(--state-opacity-disabled, 0.38);
|
|
69
|
+
pointer-events: none;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
//
|
|
73
|
+
& > * { max-inline-size: stretch; }
|
|
74
|
+
|
|
75
|
+
//
|
|
76
|
+
& :where(span, a) {
|
|
77
|
+
display: inline;
|
|
78
|
+
text-overflow: ellipsis;
|
|
79
|
+
overflow: hidden;
|
|
80
|
+
white-space: nowrap;
|
|
81
|
+
flex-wrap: nowrap;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
//
|
|
85
|
+
&:is(input) {
|
|
86
|
+
display: inline-block;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
//
|
|
91
|
+
@mixin button-overlays($fallback-color) {
|
|
92
|
+
--md-button-state-color: var(--md-button-state-color, #{$fallback-color});
|
|
93
|
+
|
|
94
|
+
@include overlays.state-overlay(var(--md-button-state-color, #{$fallback-color}));
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
@mixin button-focus-ring() {
|
|
98
|
+
@include overlays.focus-ring(var(--md-button-state-color, var(--md-primary)));
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
@mixin button-icon($size: var(--icon-size-lg)) {
|
|
102
|
+
@include overlays.icon-button($size);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
// -----------------------------------------------------------------------------
|
|
109
|
+
// Unified variant mixin
|
|
110
|
+
// -----------------------------------------------------------------------------
|
|
111
|
+
|
|
112
|
+
@mixin button-variant(
|
|
113
|
+
$variant: filled,
|
|
114
|
+
$role: primary,
|
|
115
|
+
$container-role: secondary-container,
|
|
116
|
+
$state-role: secondary,
|
|
117
|
+
$include-base: true
|
|
118
|
+
) {
|
|
119
|
+
@include colorize.solid-colorize("&", ("shade": 0.05, "tint": 0.0, "scope": "selector", "global-targets": true));
|
|
120
|
+
@if $include-base { @include button-structure; }
|
|
121
|
+
|
|
122
|
+
// Compute the CSS variable to use for state overlays
|
|
123
|
+
$state-var: if(sass($variant == tonal): color.md3-var($state-role); else: color.md3-var($role));
|
|
124
|
+
|
|
125
|
+
// Common CSS variable setup
|
|
126
|
+
--md-button-bg: color-mix(in oklch, var(--surface-color, transparent) 90%, var(--on-surface-color, transparent));
|
|
127
|
+
--md-button-on: var(--on-surface-color, currentColor);
|
|
128
|
+
--md-button-outline-color: var(--border-color, transparent);
|
|
129
|
+
|
|
130
|
+
// Variant-specific styles
|
|
131
|
+
@if $variant == outlined {
|
|
132
|
+
background-color: transparent;
|
|
133
|
+
color: var(--md-button-on, var(--on-surface-color, currentColor));
|
|
134
|
+
border: 1px solid var(--md-button-outline-color, var(#{color.md3-var(outline)}));
|
|
135
|
+
} @else if $variant == text {
|
|
136
|
+
background-color: transparent;
|
|
137
|
+
color: var(--md-button-on, var(--on-surface-color, currentColor));
|
|
138
|
+
border: none;
|
|
139
|
+
} @else {
|
|
140
|
+
// filled, elevated, tonal
|
|
141
|
+
background-color: var(--surface-color, var(--surface-color, transparent));
|
|
142
|
+
color: var(--md-button-on, var(--on-surface-color, currentColor));
|
|
143
|
+
border: none;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
// Apply state overlays and focus ring
|
|
147
|
+
@include button-overlays(var(#{$state-var}));
|
|
148
|
+
@include button-focus-ring;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
// -----------------------------------------------------------------------------
|
|
153
|
+
// Variant mixins (backward compatibility wrappers)
|
|
154
|
+
// -----------------------------------------------------------------------------
|
|
155
|
+
|
|
156
|
+
@mixin button-filled($role: primary, $include-base: true) {
|
|
157
|
+
@include button-variant(filled, $role, $include-base: $include-base);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
@mixin button-elevated($role: primary, $include-base: true) {
|
|
161
|
+
@include button-variant(elevated, $role, $include-base: $include-base);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
@mixin button-tonal($container-role: secondary-container, $state-role: secondary, $include-base: true) {
|
|
165
|
+
@include button-variant(tonal, $state-role, $container-role, $state-role, $include-base: $include-base);
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
@mixin button-outlined($role: primary, $include-base: true) {
|
|
169
|
+
@include button-variant(outlined, $role, $include-base: $include-base);
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
@mixin button-text($role: primary, $include-base: true) {
|
|
173
|
+
@include button-variant(text, $role, $include-base: $include-base);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
// -----------------------------------------------------------------------------
|
|
181
|
+
// Button base mixins
|
|
182
|
+
// -----------------------------------------------------------------------------
|
|
183
|
+
|
|
184
|
+
|
|
185
|
+
@mixin button-base {
|
|
186
|
+
@include button-structure;
|
|
187
|
+
@include button-filled;
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
//
|
|
191
|
+
@mixin button-interactions($transition: var(--transition-base, var(--duration-normal))) {
|
|
192
|
+
@include motion.transition(all, $transition);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
//
|
|
196
|
+
@mixin button-colors() {
|
|
197
|
+
@include button-structure;
|
|
198
|
+
@include button-filled;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
//
|
|
202
|
+
@mixin button-base-variant() {
|
|
203
|
+
// Reuse unified structure with alternate sizing tokens
|
|
204
|
+
@include button-structure;
|
|
205
|
+
@include button-interactions;
|
|
206
|
+
@include button-colors;
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
//
|
|
210
|
+
@mixin toolbar-button {
|
|
211
|
+
font-size: var(--font-size-sm);
|
|
212
|
+
|
|
213
|
+
//
|
|
214
|
+
@include layout.container-query("md") { span { display: none; } }
|
|
215
|
+
}
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
|
|
2
|
+
// ============================================================================
|
|
3
|
+
// Content Component Styles
|
|
4
|
+
// ============================================================================
|
|
5
|
+
@mixin tabbed-content($selector: ".content-box") {
|
|
6
|
+
@at-root :host {
|
|
7
|
+
#{$selector} {
|
|
8
|
+
// ================================================================
|
|
9
|
+
// Base Layout
|
|
10
|
+
// ================================================================
|
|
11
|
+
display: grid !important;
|
|
12
|
+
grid-template-columns: subgrid;
|
|
13
|
+
grid-template-rows: subgrid;
|
|
14
|
+
grid-column: 1 / -1 !important;
|
|
15
|
+
grid-row: 1 / -1 !important;
|
|
16
|
+
z-index: 1;
|
|
17
|
+
|
|
18
|
+
// Sizing
|
|
19
|
+
inline-size: stretch;
|
|
20
|
+
block-size: stretch;
|
|
21
|
+
min-inline-size: 0px;
|
|
22
|
+
min-block-size: 0px;
|
|
23
|
+
max-inline-size: stretch;
|
|
24
|
+
max-block-size: stretch;
|
|
25
|
+
|
|
26
|
+
// Spacing
|
|
27
|
+
gap: 0px;
|
|
28
|
+
|
|
29
|
+
// Visual
|
|
30
|
+
background: none;
|
|
31
|
+
background-color: transparent !important;
|
|
32
|
+
border-radius: 0px;
|
|
33
|
+
box-shadow: none;
|
|
34
|
+
overflow: hidden;
|
|
35
|
+
position: relative;
|
|
36
|
+
pointer-events: none;
|
|
37
|
+
|
|
38
|
+
// Containment
|
|
39
|
+
contain: none;
|
|
40
|
+
|
|
41
|
+
// Drop menu mode
|
|
42
|
+
@at-root :host([sidebar-drop-menu]) & {
|
|
43
|
+
overflow: visible;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
// ================================================================
|
|
48
|
+
// Content Container
|
|
49
|
+
// ================================================================
|
|
50
|
+
#{$selector} :where(.ui-tabbed-box-content, .content) {
|
|
51
|
+
display: grid !important;
|
|
52
|
+
flex-direction: column;
|
|
53
|
+
|
|
54
|
+
// Grid layout - align with parent grid
|
|
55
|
+
grid-template-columns:
|
|
56
|
+
/*[sidebar-col] minmax(0px, var(--sidebar-inline-grid-size, 0px))
|
|
57
|
+
[button-col] minmax(0px, var(--button-inline-size, 3rem))*/
|
|
58
|
+
[content-col] minmax(0px, 1fr);
|
|
59
|
+
grid-template-rows: var(--tabbed-grid-rows);
|
|
60
|
+
grid-column: 1 / -1;
|
|
61
|
+
grid-row: 1 / -1;
|
|
62
|
+
|
|
63
|
+
// Sizing
|
|
64
|
+
inline-size: stretch;
|
|
65
|
+
block-size: stretch;
|
|
66
|
+
min-inline-size: 0px;
|
|
67
|
+
min-block-size: 0px;
|
|
68
|
+
max-inline-size: stretch;
|
|
69
|
+
max-block-size: stretch;
|
|
70
|
+
will-change: contents;
|
|
71
|
+
|
|
72
|
+
// Spacing
|
|
73
|
+
gap: 0px;
|
|
74
|
+
|
|
75
|
+
// Visual
|
|
76
|
+
background: none;
|
|
77
|
+
background-color: transparent !important;
|
|
78
|
+
border-radius: 0px;
|
|
79
|
+
box-shadow: none;
|
|
80
|
+
align-content: start;
|
|
81
|
+
pointer-events: none;
|
|
82
|
+
|
|
83
|
+
// Performance
|
|
84
|
+
container-type: inline-size;
|
|
85
|
+
content-visibility: auto;
|
|
86
|
+
contain: strict;
|
|
87
|
+
perspective: 1000;
|
|
88
|
+
transform: translateZ(0px);
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
// ================================================================
|
|
92
|
+
// Slotted Content
|
|
93
|
+
// ================================================================
|
|
94
|
+
#{$selector} ::slotted(*) {
|
|
95
|
+
display: grid;
|
|
96
|
+
flex-direction: column;
|
|
97
|
+
flex-grow: 1;
|
|
98
|
+
place-content: center;
|
|
99
|
+
place-items: center;
|
|
100
|
+
|
|
101
|
+
// Grid positioning
|
|
102
|
+
grid-column: 1 / -1;
|
|
103
|
+
grid-row: content-row;
|
|
104
|
+
grid-template-columns: minmax(0px, 1fr);
|
|
105
|
+
grid-template-rows: minmax(0px, 1fr);
|
|
106
|
+
|
|
107
|
+
// Sizing
|
|
108
|
+
inline-size: stretch;
|
|
109
|
+
block-size: stretch;
|
|
110
|
+
min-inline-size: 0px;
|
|
111
|
+
min-block-size: 0px;
|
|
112
|
+
max-inline-size: stretch;
|
|
113
|
+
max-block-size: stretch;
|
|
114
|
+
|
|
115
|
+
// Spacing
|
|
116
|
+
gap: 0px;
|
|
117
|
+
|
|
118
|
+
// Visual
|
|
119
|
+
background-color: transparent;
|
|
120
|
+
box-shadow: none;
|
|
121
|
+
line-height: var(--leading-normal, 1.5);
|
|
122
|
+
color: var(--md3-on-surface);
|
|
123
|
+
overflow: auto;
|
|
124
|
+
scrollbar-gutter: stable both-edges;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
// Hidden slotted content
|
|
128
|
+
#{$selector} ::slotted([aria-hidden="true"], [hidden], :not([active])) {
|
|
129
|
+
display: none !important;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
// ================================================================
|
|
133
|
+
// Responsive: Desktop Layout
|
|
134
|
+
// ================================================================
|
|
135
|
+
#{$selector} {
|
|
136
|
+
@container (min-inline-size: 800px) {
|
|
137
|
+
.content {
|
|
138
|
+
grid-column: 2 / -1 !important;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
// ================================================================
|
|
144
|
+
// Drop Menu Mode: Backdrop Overlay
|
|
145
|
+
// ================================================================
|
|
146
|
+
@at-root :host([sidebar-drop-menu]) #{$selector} {
|
|
147
|
+
// ================================================================
|
|
148
|
+
// Responsive: Desktop Layout
|
|
149
|
+
// ================================================================
|
|
150
|
+
@container (min-inline-size: 800px) {
|
|
151
|
+
.content {
|
|
152
|
+
isolation: isolate;
|
|
153
|
+
|
|
154
|
+
&::after {
|
|
155
|
+
content: "";
|
|
156
|
+
position: absolute;
|
|
157
|
+
inset: clamp(0px, 1cqi, 0.5rem);
|
|
158
|
+
border-radius: 0px;
|
|
159
|
+
background: color-mix(in oklch, var(--md3-surface) 60%, transparent);
|
|
160
|
+
opacity: 0;
|
|
161
|
+
pointer-events: none;
|
|
162
|
+
transition: opacity var(--transition-medium, 0.28s) var(--ease-out);
|
|
163
|
+
z-index: 4;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
}
|