@rvx/ui 0.3.8 → 0.4.0
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/dist/common/events.d.ts +0 -40
- package/dist/common/events.d.ts.map +1 -1
- package/dist/common/theme.d.ts +3 -134
- package/dist/common/theme.d.ts.map +1 -1
- package/dist/common/theme.js +25 -2
- package/dist/common/theme.js.map +1 -1
- package/dist/common/writing-mode.d.ts +0 -58
- package/dist/common/writing-mode.d.ts.map +1 -1
- package/dist/components/breadcrumbs.d.ts.map +1 -1
- package/dist/components/breadcrumbs.js +3 -4
- package/dist/components/breadcrumbs.js.map +1 -1
- package/dist/components/button.d.ts +0 -18
- package/dist/components/button.d.ts.map +1 -1
- package/dist/components/button.js +3 -4
- package/dist/components/button.js.map +1 -1
- package/dist/components/card.d.ts +1 -1
- package/dist/components/card.d.ts.map +1 -1
- package/dist/components/card.js +4 -5
- package/dist/components/card.js.map +1 -1
- package/dist/components/checkbox.d.ts.map +1 -1
- package/dist/components/checkbox.js +4 -5
- package/dist/components/checkbox.js.map +1 -1
- package/dist/components/collapse.d.ts.map +1 -1
- package/dist/components/collapse.js +7 -10
- package/dist/components/collapse.js.map +1 -1
- package/dist/components/column.d.ts +0 -6
- package/dist/components/column.d.ts.map +1 -1
- package/dist/components/column.js +4 -5
- package/dist/components/column.js.map +1 -1
- package/dist/components/control-group.d.ts.map +1 -1
- package/dist/components/control-group.js +3 -4
- package/dist/components/control-group.js.map +1 -1
- package/dist/components/dialog.d.ts +1 -1
- package/dist/components/dialog.d.ts.map +1 -1
- package/dist/components/dialog.js +14 -10
- package/dist/components/dialog.js.map +1 -1
- package/dist/components/dropdown-input.d.ts +1 -1
- package/dist/components/dropdown-input.d.ts.map +1 -1
- package/dist/components/dropdown.d.ts +0 -88
- package/dist/components/dropdown.d.ts.map +1 -1
- package/dist/components/dropdown.js +7 -8
- package/dist/components/dropdown.js.map +1 -1
- package/dist/components/error.d.ts.map +1 -1
- package/dist/components/error.js +2 -3
- package/dist/components/error.js.map +1 -1
- package/dist/components/flex-space.d.ts.map +1 -1
- package/dist/components/flex-space.js +3 -4
- package/dist/components/flex-space.js.map +1 -1
- package/dist/components/heading.d.ts +0 -3
- package/dist/components/heading.d.ts.map +1 -1
- package/dist/components/heading.js +2 -3
- package/dist/components/heading.js.map +1 -1
- package/dist/components/label.d.ts.map +1 -1
- package/dist/components/label.js +2 -3
- package/dist/components/label.js.map +1 -1
- package/dist/components/layer.d.ts +0 -63
- package/dist/components/layer.d.ts.map +1 -1
- package/dist/components/link.d.ts +0 -33
- package/dist/components/link.d.ts.map +1 -1
- package/dist/components/link.js +2 -3
- package/dist/components/link.js.map +1 -1
- package/dist/components/nav-list.d.ts +0 -8
- package/dist/components/nav-list.d.ts.map +1 -1
- package/dist/components/nav-list.js +4 -6
- package/dist/components/nav-list.js.map +1 -1
- package/dist/components/notifications.d.ts +4 -1
- package/dist/components/notifications.d.ts.map +1 -1
- package/dist/components/notifications.js +5 -11
- package/dist/components/notifications.js.map +1 -1
- package/dist/components/page.d.ts.map +1 -1
- package/dist/components/page.js +4 -5
- package/dist/components/page.js.map +1 -1
- package/dist/components/placeholder.d.ts.map +1 -1
- package/dist/components/placeholder.js +3 -4
- package/dist/components/placeholder.js.map +1 -1
- package/dist/components/popout.d.ts +0 -96
- package/dist/components/popout.d.ts.map +1 -1
- package/dist/components/popover.d.ts +0 -88
- package/dist/components/popover.d.ts.map +1 -1
- package/dist/components/popover.js +9 -9
- package/dist/components/popover.js.map +1 -1
- package/dist/components/radio-buttons.d.ts.map +1 -1
- package/dist/components/radio-buttons.js +4 -5
- package/dist/components/radio-buttons.js.map +1 -1
- package/dist/components/row.d.ts.map +1 -1
- package/dist/components/row.js +4 -5
- package/dist/components/row.js.map +1 -1
- package/dist/components/scroll-view.d.ts.map +1 -1
- package/dist/components/scroll-view.js +8 -9
- package/dist/components/scroll-view.js.map +1 -1
- package/dist/components/secondary.d.ts.map +1 -1
- package/dist/components/secondary.js +2 -3
- package/dist/components/secondary.js.map +1 -1
- package/dist/components/separated.d.ts.map +1 -1
- package/dist/components/separated.js +2 -3
- package/dist/components/separated.js.map +1 -1
- package/dist/components/slider.d.ts.map +1 -1
- package/dist/components/slider.js +2 -3
- package/dist/components/slider.js.map +1 -1
- package/dist/components/tabs.d.ts.map +1 -1
- package/dist/components/tabs.js +8 -9
- package/dist/components/tabs.js.map +1 -1
- package/dist/components/text-input.d.ts +0 -31
- package/dist/components/text-input.d.ts.map +1 -1
- package/dist/components/text-input.js +2 -3
- package/dist/components/text-input.js.map +1 -1
- package/dist/components/text.d.ts.map +1 -1
- package/dist/components/text.js +2 -3
- package/dist/components/text.js.map +1 -1
- package/dist/components/validation-rules.d.ts +0 -2
- package/dist/components/validation-rules.d.ts.map +1 -1
- package/dist/components/validation.d.ts +0 -49
- package/dist/components/validation.d.ts.map +1 -1
- package/dist/components/value.d.ts.map +1 -1
- package/dist/components/value.js +2 -3
- package/dist/components/value.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/package.json +12 -7
- package/src/common/theme.tsx +28 -163
- package/src/components/breadcrumbs.tsx +4 -5
- package/src/components/button.tsx +3 -4
- package/src/components/card.tsx +5 -6
- package/src/components/checkbox.tsx +5 -7
- package/src/components/collapse.tsx +9 -13
- package/src/components/column.tsx +4 -5
- package/src/components/control-group.tsx +3 -4
- package/src/components/dialog.tsx +14 -11
- package/src/components/dropdown-input.tsx +1 -1
- package/src/components/dropdown.tsx +7 -8
- package/src/components/error.tsx +2 -3
- package/src/components/flex-space.tsx +3 -4
- package/src/components/heading.tsx +2 -3
- package/src/components/label.tsx +2 -3
- package/src/components/link.tsx +2 -3
- package/src/components/nav-list.tsx +4 -6
- package/src/components/notifications.tsx +15 -17
- package/src/components/page.tsx +6 -7
- package/src/components/placeholder.tsx +5 -6
- package/src/components/popover.tsx +10 -10
- package/src/components/radio-buttons.tsx +6 -7
- package/src/components/row.tsx +4 -5
- package/src/components/scroll-view.tsx +8 -9
- package/src/components/secondary.tsx +2 -3
- package/src/components/separated.tsx +2 -3
- package/src/components/slider.tsx +2 -5
- package/src/components/tabs.tsx +8 -9
- package/src/components/text-input.tsx +2 -3
- package/src/components/text.tsx +2 -3
- package/src/components/value.tsx +2 -3
- package/src/index.tsx +2 -0
- package/src/types.d.ts +5 -0
- package/{src/theme/components/breadcrumbs.scss → theme/components/breadcrumbs.module.css} +12 -12
- package/theme/components/button.module.css +168 -0
- package/theme/components/card.module.css +50 -0
- package/{src/theme/components/checkbox.scss → theme/components/checkbox.module.css} +5 -5
- package/{src/theme/components/collapse.scss → theme/components/collapse.module.css} +19 -19
- package/{src/theme/components/column.scss → theme/components/column.module.css} +32 -10
- package/{src/theme/components/control-group.scss → theme/components/control-group.module.css} +2 -2
- package/theme/components/dialog.module.css +63 -0
- package/{src/theme/components/dropdown.scss → theme/components/dropdown.module.css} +9 -9
- package/theme/components/error.module.css +4 -0
- package/{src/theme/components/heading.scss → theme/components/heading.module.css} +8 -8
- package/{src/theme/components/label.scss → theme/components/label.module.css} +2 -10
- package/{src/theme/components/link.scss → theme/components/link.module.css} +0 -1
- package/theme/components/nav-list.module.css +76 -0
- package/theme/components/notifications.module.css +31 -0
- package/{src/theme/components/page.scss → theme/components/page.module.css} +6 -10
- package/{src/theme/components/placeholder.scss → theme/components/placeholder.module.css} +3 -3
- package/{src/theme/components/popover.scss → theme/components/popover.module.css} +9 -9
- package/theme/components/row.module.css +36 -0
- package/{src/theme/components/scroll-view.scss → theme/components/scroll-view.module.css} +19 -21
- package/theme/components/secondary.module.css +4 -0
- package/{src/theme/components/separated.scss → theme/components/separated.module.css} +2 -2
- package/{src/theme/components/slider.scss → theme/components/slider.module.css} +2 -1
- package/theme/components/tabs.module.css +71 -0
- package/theme/components/text-input.module.css +45 -0
- package/theme/global.css +118 -0
- package/dist/common/theme-test.d.ts +0 -8
- package/dist/common/theme-test.d.ts.map +0 -1
- package/dist/common/theme-test.js +0 -13
- package/dist/common/theme-test.js.map +0 -1
- package/dist/components/checkbox-test.d.ts +0 -4
- package/dist/components/checkbox-test.d.ts.map +0 -1
- package/dist/components/checkbox-test.js +0 -31
- package/dist/components/checkbox-test.js.map +0 -1
- package/dist/components/collapse-test.d.ts +0 -9
- package/dist/components/collapse-test.d.ts.map +0 -1
- package/dist/components/collapse-test.js +0 -15
- package/dist/components/collapse-test.js.map +0 -1
- package/dist/test.d.ts +0 -4
- package/dist/test.d.ts.map +0 -1
- package/dist/test.js +0 -4
- package/dist/test.js.map +0 -1
- package/dist/theme.module.css +0 -1290
- package/dist/theme.module.css.map +0 -1
- package/src/common/theme-test.tsx +0 -18
- package/src/components/checkbox-test.tsx +0 -35
- package/src/components/collapse-test.tsx +0 -23
- package/src/test.tsx +0 -3
- package/src/theme/base.scss +0 -121
- package/src/theme/common.scss +0 -42
- package/src/theme/components/button.scss +0 -164
- package/src/theme/components/card.scss +0 -41
- package/src/theme/components/dialog.scss +0 -65
- package/src/theme/components/error.scss +0 -12
- package/src/theme/components/nav-list.scss +0 -91
- package/src/theme/components/notifications.scss +0 -61
- package/src/theme/components/row.scss +0 -22
- package/src/theme/components/secondary.scss +0 -4
- package/src/theme/components/tabs.scss +0 -90
- package/src/theme/components/text-input.scss +0 -50
- package/src/theme/theme.scss +0 -31
- /package/{src/theme/components/flex-space.scss → theme/components/flex-space.module.css} +0 -0
- /package/{src/theme/components/radio-buttons.scss → theme/components/radio-buttons.module.css} +0 -0
- /package/{src/theme/components/text.scss → theme/components/text.module.css} +0 -0
- /package/{src/theme/components/value.scss → theme/components/value.module.css} +0 -0
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import
|
|
1
|
+
import styles from "@rvx/ui/theme/components/secondary.module.css";
|
|
2
2
|
|
|
3
3
|
export function Secondary(props: {
|
|
4
4
|
children?: unknown;
|
|
5
5
|
}): unknown {
|
|
6
|
-
|
|
7
|
-
return <span class={[theme?.secondary]} >
|
|
6
|
+
return <span class={styles.secondary}>
|
|
8
7
|
{props.children}
|
|
9
8
|
</span>;
|
|
10
9
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import styles from "@rvx/ui/theme/components/separated.module.css";
|
|
1
2
|
import { ClassValue, Expression, map, StyleValue } from "rvx";
|
|
2
|
-
import { THEME } from "../common/theme.js";
|
|
3
3
|
|
|
4
4
|
export function Separated(props: {
|
|
5
5
|
class?: ClassValue;
|
|
@@ -8,11 +8,10 @@ export function Separated(props: {
|
|
|
8
8
|
children?: unknown;
|
|
9
9
|
row?: Expression<boolean | undefined>;
|
|
10
10
|
}) {
|
|
11
|
-
const theme = THEME.current;
|
|
12
11
|
return <div
|
|
13
12
|
class={[
|
|
14
13
|
props.class,
|
|
15
|
-
map(props.row, row => row ?
|
|
14
|
+
map(props.row, row => row ? styles.row : styles.column),
|
|
16
15
|
]}
|
|
17
16
|
style={props.style}
|
|
18
17
|
id={props.id}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import styles from "@rvx/ui/theme/components/slider.module.css";
|
|
1
2
|
import { Expression, map, Show, Signal, uniqueId } from "rvx";
|
|
2
3
|
import { ID_PAIR } from "../common/id-pairs.js";
|
|
3
|
-
import { THEME } from "../common/theme.js";
|
|
4
4
|
|
|
5
5
|
export function Slider(props: {
|
|
6
6
|
id?: Expression<string | undefined>;
|
|
@@ -11,7 +11,6 @@ export function Slider(props: {
|
|
|
11
11
|
markers?: Expression<number[] | undefined>;
|
|
12
12
|
children?: unknown;
|
|
13
13
|
}) {
|
|
14
|
-
const theme = THEME.current;
|
|
15
14
|
const markerId = uniqueId();
|
|
16
15
|
const id = props.id ?? ID_PAIR.current.consume();
|
|
17
16
|
|
|
@@ -30,9 +29,7 @@ export function Slider(props: {
|
|
|
30
29
|
list={map(props.markers, markers => markers ? markerId : undefined)}
|
|
31
30
|
/> as HTMLInputElement;
|
|
32
31
|
|
|
33
|
-
return <div
|
|
34
|
-
class={theme?.slider_host}
|
|
35
|
-
>
|
|
32
|
+
return <div class={styles.host}>
|
|
36
33
|
{input}
|
|
37
34
|
|
|
38
35
|
<Show when={props.markers}>
|
package/src/components/tabs.tsx
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import separatedStyles from "@rvx/ui/theme/components/separated.module.css";
|
|
2
|
+
import styles from "@rvx/ui/theme/components/tabs.module.css";
|
|
1
3
|
import { $, ClassValue, Component, Expression, For, get, map, Show, Signal, StyleValue, uniqueIdFor, watch } from "rvx";
|
|
2
4
|
import { string } from "rvx/convert";
|
|
3
|
-
import { THEME } from "../common/theme.js";
|
|
4
5
|
|
|
5
6
|
export interface Tab {
|
|
6
7
|
label: Component;
|
|
@@ -44,13 +45,12 @@ export function TabList(props: {
|
|
|
44
45
|
class?: ClassValue;
|
|
45
46
|
style?: StyleValue;
|
|
46
47
|
}) {
|
|
47
|
-
const theme = THEME.current;
|
|
48
48
|
return <div
|
|
49
49
|
role="tablist"
|
|
50
50
|
class={[
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
map(props.padded, padded => padded ?
|
|
51
|
+
styles.list,
|
|
52
|
+
separatedStyles.has_separator,
|
|
53
|
+
map(props.padded, padded => padded ? styles.list_padded : undefined),
|
|
54
54
|
props.class,
|
|
55
55
|
]}
|
|
56
56
|
style={props.style}
|
|
@@ -59,8 +59,8 @@ export function TabList(props: {
|
|
|
59
59
|
{tab => <button
|
|
60
60
|
role="tab"
|
|
61
61
|
class={[
|
|
62
|
-
|
|
63
|
-
() => props.selected.value === tab ?
|
|
62
|
+
styles.handle,
|
|
63
|
+
() => props.selected.value === tab ? styles.handle_current : undefined,
|
|
64
64
|
]}
|
|
65
65
|
aria-selected={string(() => props.selected.value === tab)}
|
|
66
66
|
aria-controls={uniqueIdFor(tab)}
|
|
@@ -82,13 +82,12 @@ export function TabPanel(props: {
|
|
|
82
82
|
style?: StyleValue;
|
|
83
83
|
content?: Component<Component>;
|
|
84
84
|
}) {
|
|
85
|
-
const theme = THEME.current;
|
|
86
85
|
return <Show when={props.tab}>
|
|
87
86
|
{tab => <div
|
|
88
87
|
role="tabpanel"
|
|
89
88
|
id={uniqueIdFor(tab)}
|
|
90
89
|
class={[
|
|
91
|
-
|
|
90
|
+
styles.panel,
|
|
92
91
|
props.class,
|
|
93
92
|
]}
|
|
94
93
|
style={props.style}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import styles from "@rvx/ui/theme/components/text-input.module.css";
|
|
1
2
|
import { ClassValue, Expression, get, Signal, StyleValue } from "rvx";
|
|
2
3
|
import { isPending } from "rvx/async";
|
|
3
4
|
import { optionalString } from "rvx/convert";
|
|
4
5
|
import { ID_PAIR } from "../common/id-pairs.js";
|
|
5
|
-
import { THEME } from "../common/theme.js";
|
|
6
6
|
import { closestValidator } from "./validation.js";
|
|
7
7
|
|
|
8
8
|
export type TextInputType = "text" | "password";
|
|
@@ -63,7 +63,6 @@ export function TextInput(props: ({
|
|
|
63
63
|
"aria-labelledby"?: Expression<string | undefined>;
|
|
64
64
|
}): unknown {
|
|
65
65
|
const id = props.id ?? ID_PAIR.current.consume();
|
|
66
|
-
const theme = THEME.current;
|
|
67
66
|
const disabled = () => isPending() || get(props.disabled);
|
|
68
67
|
|
|
69
68
|
const validator = props.value instanceof Signal ? closestValidator(props.value) : undefined;
|
|
@@ -75,7 +74,7 @@ export function TextInput(props: ({
|
|
|
75
74
|
wrap={props.multiline ? props.wrap : undefined}
|
|
76
75
|
disabled={disabled}
|
|
77
76
|
class={[
|
|
78
|
-
|
|
77
|
+
styles.text_input,
|
|
79
78
|
props.class,
|
|
80
79
|
]}
|
|
81
80
|
style={props.style}
|
package/src/components/text.tsx
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import styles from "@rvx/ui/theme/components/text.module.css";
|
|
1
2
|
import { ClassValue, Expression, StyleValue } from "rvx";
|
|
2
|
-
import { THEME } from "../common/theme.js";
|
|
3
3
|
|
|
4
4
|
export function Text(props: {
|
|
5
5
|
class?: ClassValue;
|
|
@@ -7,10 +7,9 @@ export function Text(props: {
|
|
|
7
7
|
id?: Expression<string | undefined>;
|
|
8
8
|
children?: unknown;
|
|
9
9
|
}): unknown {
|
|
10
|
-
const theme = THEME.current;
|
|
11
10
|
return <div
|
|
12
11
|
class={[
|
|
13
|
-
|
|
12
|
+
styles.text,
|
|
14
13
|
props.class,
|
|
15
14
|
]}
|
|
16
15
|
style={props.style}
|
package/src/components/value.tsx
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import
|
|
1
|
+
import styles from "@rvx/ui/theme/components/value.module.css";
|
|
2
2
|
|
|
3
3
|
export function Value(props: {
|
|
4
4
|
children?: unknown;
|
|
5
5
|
}): unknown {
|
|
6
|
-
|
|
7
|
-
return <span class={[theme?.value]} >
|
|
6
|
+
return <span class={styles.value}>
|
|
8
7
|
{props.children}
|
|
9
8
|
</span>;
|
|
10
9
|
}
|
package/src/index.tsx
CHANGED
package/src/types.d.ts
ADDED
|
@@ -1,11 +1,3 @@
|
|
|
1
|
-
@use "../common";
|
|
2
|
-
|
|
3
|
-
@include common.theme((
|
|
4
|
-
breadcrumb-separator: (
|
|
5
|
-
dark: rgb(120, 120, 120),
|
|
6
|
-
light: rgb(180, 180, 180),
|
|
7
|
-
),
|
|
8
|
-
));
|
|
9
1
|
|
|
10
2
|
.breadcrumbs {
|
|
11
3
|
flex-wrap: wrap;
|
|
@@ -13,7 +5,7 @@
|
|
|
13
5
|
row-gap: var(--control-row-gap);
|
|
14
6
|
}
|
|
15
7
|
|
|
16
|
-
.breadcrumbs, .
|
|
8
|
+
.breadcrumbs, .item {
|
|
17
9
|
display: flex;
|
|
18
10
|
flex-direction: row;
|
|
19
11
|
align-items: center;
|
|
@@ -21,18 +13,26 @@
|
|
|
21
13
|
row-gap: var(--control-row-gap);
|
|
22
14
|
}
|
|
23
15
|
|
|
24
|
-
.
|
|
16
|
+
.item {
|
|
25
17
|
line-height: calc(1em + var(--line-gap));
|
|
26
18
|
margin-block: calc(var(--line-gap) / -2);
|
|
27
19
|
}
|
|
28
20
|
|
|
29
|
-
.
|
|
21
|
+
.separator {
|
|
30
22
|
block-size: calc(1em + var(--line-gap));
|
|
31
23
|
display: block;
|
|
32
24
|
position: relative;
|
|
33
25
|
}
|
|
34
26
|
|
|
35
|
-
.
|
|
27
|
+
.separator svg {
|
|
36
28
|
block-size: 100%;
|
|
37
29
|
stroke: var(--breadcrumb-separator);
|
|
38
30
|
}
|
|
31
|
+
|
|
32
|
+
:global(.rvx-dark) {
|
|
33
|
+
--breadcrumb-separator: rgb(120 120 120);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
:global(.rvx-light) {
|
|
37
|
+
--breadcrumb-separator: rgb(180 180 180);
|
|
38
|
+
}
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
|
|
2
|
+
.button {
|
|
3
|
+
font-family: inherit;
|
|
4
|
+
font-size: inherit;
|
|
5
|
+
font-weight: 600;
|
|
6
|
+
line-height: 1;
|
|
7
|
+
|
|
8
|
+
cursor: pointer;
|
|
9
|
+
|
|
10
|
+
outline: none;
|
|
11
|
+
padding-block: var(--control-padding-block);
|
|
12
|
+
padding-inline: var(--control-padding-inline);
|
|
13
|
+
|
|
14
|
+
border-radius: var(--control-radius);
|
|
15
|
+
border-width: var(--control-border);
|
|
16
|
+
|
|
17
|
+
transition:
|
|
18
|
+
background-color var(--transition-color),
|
|
19
|
+
color var(--transition-color),
|
|
20
|
+
border-color var(--transition-color);
|
|
21
|
+
|
|
22
|
+
&[disabled] {
|
|
23
|
+
cursor: default;
|
|
24
|
+
filter: var(--control-disabled);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
background-color: var(--button-bg);
|
|
28
|
+
color: var(--button-fg);
|
|
29
|
+
border: var(--control-border) solid var(--button-border, var(--button-bg));
|
|
30
|
+
|
|
31
|
+
&:hover:not(:active):not([disabled]) {
|
|
32
|
+
background-color: var(--button-active);
|
|
33
|
+
&:not(:focus-visible) {
|
|
34
|
+
border-color: var(--button-active);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
&:focus-visible {
|
|
39
|
+
border-color: var(--button-focus);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.default {
|
|
44
|
+
--button-bg: var(--button-default-bg);
|
|
45
|
+
--button-fg: var(--button-default-fg);
|
|
46
|
+
--button-active: var(--button-default-active);
|
|
47
|
+
--button-focus: var(--button-default-focus);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.primary {
|
|
51
|
+
--button-bg: var(--button-primary-bg);
|
|
52
|
+
--button-fg: var(--button-primary-fg);
|
|
53
|
+
--button-active: var(--button-primary-active);
|
|
54
|
+
--button-focus: var(--button-primary-focus);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.success {
|
|
58
|
+
--button-bg: var(--button-success-bg);
|
|
59
|
+
--button-fg: var(--button-success-fg);
|
|
60
|
+
--button-active: var(--button-success-active);
|
|
61
|
+
--button-focus: var(--button-success-focus);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.warning {
|
|
65
|
+
--button-bg: var(--button-warning-bg);
|
|
66
|
+
--button-fg: var(--button-warning-fg);
|
|
67
|
+
--button-active: var(--button-warning-active);
|
|
68
|
+
--button-focus: var(--button-warning-focus);
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.danger {
|
|
72
|
+
--button-bg: var(--button-danger-bg);
|
|
73
|
+
--button-fg: var(--button-danger-fg);
|
|
74
|
+
--button-active: var(--button-danger-active);
|
|
75
|
+
--button-focus: var(--button-danger-focus);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.input {
|
|
79
|
+
text-align: left;
|
|
80
|
+
--button-bg: var(--button-input-bg);
|
|
81
|
+
--button-fg: var(--button-input-fg);
|
|
82
|
+
--button-active: var(--button-input-active);
|
|
83
|
+
--button-focus: var(--button-input-focus);
|
|
84
|
+
--button-border: var(--button-input-border);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.item {
|
|
88
|
+
--button-bg: var(--button-item-bg);
|
|
89
|
+
--button-fg: var(--button-item-fg);
|
|
90
|
+
--button-active: var(--button-item-active);
|
|
91
|
+
--button-focus: var(--button-item-focus);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
:global(.rvx-dark) {
|
|
95
|
+
--button-default-bg: rgb(72 72 72);
|
|
96
|
+
--button-default-fg: white;
|
|
97
|
+
--button-default-active: rgb(100 100 100);
|
|
98
|
+
--button-default-focus: var(--accent);
|
|
99
|
+
|
|
100
|
+
--button-primary-bg: rgb(64 160 255);
|
|
101
|
+
--button-primary-fg: black;
|
|
102
|
+
--button-primary-active: rgb(112 184 255);
|
|
103
|
+
--button-primary-focus: rgb(200 241 255);
|
|
104
|
+
|
|
105
|
+
--button-success-bg: rgb(64 255 64);
|
|
106
|
+
--button-success-fg: black;
|
|
107
|
+
--button-success-active: rgb(160 255 160);
|
|
108
|
+
--button-success-focus: rgb(224 255 224);
|
|
109
|
+
|
|
110
|
+
--button-warning-bg: rgb(255 200 0);
|
|
111
|
+
--button-warning-fg: black;
|
|
112
|
+
--button-warning-active: rgb(255 224 112);
|
|
113
|
+
--button-warning-focus: rgb(255 243 200);
|
|
114
|
+
|
|
115
|
+
--button-danger-bg: rgb(255 40 40);
|
|
116
|
+
--button-danger-fg: black;
|
|
117
|
+
--button-danger-active: rgb(255 100 100);
|
|
118
|
+
--button-danger-focus: rgb(255 200 200);
|
|
119
|
+
|
|
120
|
+
--button-input-bg: rgb(36 36 36);
|
|
121
|
+
--button-input-fg: white;
|
|
122
|
+
--button-input-border: rgb(54 54 54);
|
|
123
|
+
--button-input-active: rgb(64 64 64);
|
|
124
|
+
--button-input-focus: var(--accent);
|
|
125
|
+
|
|
126
|
+
--button-item-bg: rgb(48 48 48);
|
|
127
|
+
--button-item-fg: white;
|
|
128
|
+
--button-item-active: rgb(64 64 64);
|
|
129
|
+
--button-item-focus: var(--accent);
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
:global(.rvx-light) {
|
|
133
|
+
--button-default-bg: rgb(224 224 224);
|
|
134
|
+
--button-default-fg: black;
|
|
135
|
+
--button-default-active: rgb(200 200 200);
|
|
136
|
+
--button-default-focus: var(--accent);
|
|
137
|
+
|
|
138
|
+
--button-primary-bg: rgb(0 127 255);
|
|
139
|
+
--button-primary-fg: white;
|
|
140
|
+
--button-primary-active: rgb(64 160 255);
|
|
141
|
+
--button-primary-focus: rgb(0 56 112);
|
|
142
|
+
|
|
143
|
+
--button-success-bg: rgb(0 255 0);
|
|
144
|
+
--button-success-fg: black;
|
|
145
|
+
--button-success-active: rgb(130 255 130);
|
|
146
|
+
--button-success-focus: rgb(0 160 0);
|
|
147
|
+
|
|
148
|
+
--button-warning-bg: rgb(255 200 0);
|
|
149
|
+
--button-warning-fg: black;
|
|
150
|
+
--button-warning-active: rgb(255 224 112);
|
|
151
|
+
--button-warning-focus: rgb(150 117 0);
|
|
152
|
+
|
|
153
|
+
--button-danger-bg: rgb(255 40 40);
|
|
154
|
+
--button-danger-fg: white;
|
|
155
|
+
--button-danger-active: rgb(255 80 80);
|
|
156
|
+
--button-danger-focus: rgb(130 0 0);
|
|
157
|
+
|
|
158
|
+
--button-input-bg: rgb(250 250 250);
|
|
159
|
+
--button-input-fg: black;
|
|
160
|
+
--button-input-border: rgb(220 220 220);
|
|
161
|
+
--button-input-active: rgb(230 230 230);
|
|
162
|
+
--button-input-focus: var(--accent);
|
|
163
|
+
|
|
164
|
+
--button-item-bg: rgb(230 230 230);
|
|
165
|
+
--button-item-fg: black;
|
|
166
|
+
--button-item-active: rgb(215 215 215);
|
|
167
|
+
--button-item-focus: var(--accent);
|
|
168
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
|
|
2
|
+
.card {
|
|
3
|
+
box-shadow: var(--content-shadow);
|
|
4
|
+
border-radius: var(--content-radius);
|
|
5
|
+
background-color: var(--bg-alt);
|
|
6
|
+
--parent-bg: var(--bg-alt);
|
|
7
|
+
|
|
8
|
+
border: var(--content-border) solid transparent;
|
|
9
|
+
|
|
10
|
+
&:not(.raw) {
|
|
11
|
+
padding-block: var(--content-padding-block);
|
|
12
|
+
padding-inline: var(--content-padding-inline);
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.default {
|
|
17
|
+
border-color: var(--card-default);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.info {
|
|
21
|
+
border-color: var(--card-info);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.success {
|
|
25
|
+
border-color: var(--card-success);
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.warning {
|
|
29
|
+
border-color: var(--card-warning);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.danger {
|
|
33
|
+
border-color: var(--card-danger);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
:global(.rvx-dark) {
|
|
37
|
+
--card-default: var(--default-border);
|
|
38
|
+
--card-info: rgb(64 160 255);
|
|
39
|
+
--card-success: rgb(64 255 64);
|
|
40
|
+
--card-warning: rgb(255 200 0);
|
|
41
|
+
--card-danger: rgb(255 64 64);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
:global(.rvx-light) {
|
|
45
|
+
--card-default: var(--default-border);
|
|
46
|
+
--card-info: rgb(0 127 255);
|
|
47
|
+
--card-success: rgb(0 255 0);
|
|
48
|
+
--card-warning: rgb(255 160 0);
|
|
49
|
+
--card-danger: rgb(255 0 0);
|
|
50
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
.
|
|
2
|
+
.label {
|
|
3
3
|
display: flex;
|
|
4
4
|
column-gap: var(--control-column-gap);
|
|
5
5
|
align-items: start;
|
|
@@ -8,22 +8,22 @@
|
|
|
8
8
|
cursor: pointer;
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
-
&:has(.
|
|
11
|
+
&:has(.input:disabled) > .content {
|
|
12
12
|
filter: var(--control-disabled);
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
&:has(.
|
|
15
|
+
&:has(.input:focus-visible) {
|
|
16
16
|
outline: var(--focus-outline);
|
|
17
17
|
outline-offset: var(--focus-outline-offset);
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
.
|
|
21
|
+
.padding {
|
|
22
22
|
padding: var(--input-extension);
|
|
23
23
|
margin: calc(var(--input-extension) * -1);
|
|
24
24
|
}
|
|
25
25
|
|
|
26
|
-
.
|
|
26
|
+
.input {
|
|
27
27
|
margin: 0;
|
|
28
28
|
outline: none;
|
|
29
29
|
cursor: inherit;
|
|
@@ -6,60 +6,60 @@
|
|
|
6
6
|
--space-scale: 0;
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
-
.
|
|
9
|
+
.sized {
|
|
10
10
|
transition:
|
|
11
|
-
margin-block-start var(--layout
|
|
12
|
-
margin-block-end var(--layout
|
|
13
|
-
opacity var(--layout
|
|
11
|
+
margin-block-start var(--transition-layout),
|
|
12
|
+
margin-block-end var(--transition-layout),
|
|
13
|
+
opacity var(--transition-layout);
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
@keyframes alert {
|
|
17
17
|
from { transform: translateX(0rem); }
|
|
18
|
-
30% { transform: translateX(
|
|
19
|
-
70% { transform: translateX(
|
|
18
|
+
30% { transform: translateX(calc(3rem / 14)); }
|
|
19
|
+
70% { transform: translateX(calc(-3rem / 14)); }
|
|
20
20
|
to { transform: translateX(0rem); }
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
-
.
|
|
23
|
+
.alert {
|
|
24
24
|
animation: alert .2s ease;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
|
-
.
|
|
27
|
+
.visible.visible {
|
|
28
28
|
--space-scale: 1;
|
|
29
29
|
opacity: 1;
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
.
|
|
32
|
+
.view {
|
|
33
33
|
block-size: 0px;
|
|
34
34
|
position: relative;
|
|
35
35
|
overflow: hidden;
|
|
36
36
|
|
|
37
|
-
.
|
|
37
|
+
.sized > & {
|
|
38
38
|
transition:
|
|
39
|
-
block-size var(--layout
|
|
40
|
-
margin var(--layout
|
|
39
|
+
block-size var(--transition-layout),
|
|
40
|
+
margin var(--transition-layout);
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
.
|
|
43
|
+
.visible > & {
|
|
44
44
|
block-size: calc(var(--collapse-size) + var(--overflow-safe-area) * 2);
|
|
45
45
|
margin: calc(var(--overflow-safe-area) * -1);
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
-
.
|
|
49
|
+
.content {
|
|
50
50
|
position: absolute;
|
|
51
51
|
inline-size: 100%;
|
|
52
52
|
top: 0px;
|
|
53
53
|
left: 0px;
|
|
54
54
|
|
|
55
|
-
.
|
|
55
|
+
.sized > * > & {
|
|
56
56
|
transition:
|
|
57
|
-
top var(--layout
|
|
58
|
-
left var(--layout
|
|
59
|
-
inline-size var(--layout
|
|
57
|
+
top var(--transition-layout),
|
|
58
|
+
left var(--transition-layout),
|
|
59
|
+
inline-size var(--transition-layout);
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
.
|
|
62
|
+
.visible & {
|
|
63
63
|
top: var(--overflow-safe-area);
|
|
64
64
|
left: var(--overflow-safe-area);
|
|
65
65
|
inline-size: calc(100% - var(--overflow-safe-area) * 2);
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
@use "../common";
|
|
2
1
|
|
|
3
2
|
.column {
|
|
4
3
|
display: flex;
|
|
@@ -27,15 +26,38 @@
|
|
|
27
26
|
}
|
|
28
27
|
}
|
|
29
28
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
29
|
+
.content {
|
|
30
|
+
row-gap: var(--content-row-gap);
|
|
31
|
+
& > * {
|
|
32
|
+
--parent-row-gap: var(--content-row-gap);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
&.padded {
|
|
36
|
+
padding-block: var(--content-padding-block);
|
|
37
|
+
padding-inline: var(--content-padding-inline);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.group {
|
|
42
|
+
row-gap: var(--group-row-gap);
|
|
43
|
+
& > * {
|
|
44
|
+
--parent-row-gap: var(--group-row-gap);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
&.padded {
|
|
48
|
+
padding-block: var(--group-padding-block);
|
|
49
|
+
padding-inline: var(--group-padding-inline);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.control {
|
|
54
|
+
row-gap: var(--control-row-gap);
|
|
55
|
+
& > * {
|
|
56
|
+
--parent-row-gap: var(--control-row-gap);
|
|
57
|
+
}
|
|
36
58
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
59
|
+
&.padded {
|
|
60
|
+
padding-block: var(--control-padding-block);
|
|
61
|
+
padding-inline: var(--control-padding-inline);
|
|
40
62
|
}
|
|
41
63
|
}
|
package/{src/theme/components/control-group.scss → theme/components/control-group.module.css}
RENAMED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
}
|
|
11
11
|
}
|
|
12
12
|
|
|
13
|
-
.
|
|
13
|
+
.row {
|
|
14
14
|
flex-direction: row;
|
|
15
15
|
& > :first-child {
|
|
16
16
|
border-start-start-radius: inherit;
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
32
|
|
|
33
|
-
.
|
|
33
|
+
.column {
|
|
34
34
|
flex-direction: column;
|
|
35
35
|
& > :first-child {
|
|
36
36
|
border-start-start-radius: inherit;
|