@smwb/ui-styles 1.0.5 → 1.1.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.
@@ -0,0 +1,2 @@
1
+ @import (reference) "../../_prelude.less";
2
+ @import "./assetGrid.less";
@@ -0,0 +1,30 @@
1
+ .smwb-asset-grid {
2
+ position: relative;
3
+ overflow-y: auto;
4
+ width: 100%;
5
+
6
+ &__empty {
7
+ display: flex;
8
+ align-items: center;
9
+ justify-content: center;
10
+ padding: 32px 16px;
11
+ color: var(--smui-onSurfaceColor);
12
+ opacity: 0.7;
13
+ }
14
+
15
+ &__skeleton {
16
+ border-radius: 8px;
17
+ background-color: var(--smui-surfaceVariant);
18
+ animation: smwb-asset-grid-pulse 1.4s ease-in-out infinite;
19
+ }
20
+ }
21
+
22
+ @keyframes smwb-asset-grid-pulse {
23
+ 0%,
24
+ 100% {
25
+ opacity: 1;
26
+ }
27
+ 50% {
28
+ opacity: 0.5;
29
+ }
30
+ }
@@ -0,0 +1,2 @@
1
+ @import (reference) "../../_prelude.less";
2
+ @import "./chipGroup.less";
@@ -0,0 +1,6 @@
1
+ .smwb-chip-group {
2
+ display: flex;
3
+ flex-wrap: wrap;
4
+ align-items: center;
5
+ gap: 8px;
6
+ }
@@ -0,0 +1,2 @@
1
+ @import (reference) "../../_prelude.less";
2
+ @import "./lazyImage.less";
@@ -0,0 +1,24 @@
1
+ .smwb-lazy-image {
2
+ display: block;
3
+ position: relative;
4
+ overflow: hidden;
5
+ width: 100%;
6
+ height: 100%;
7
+
8
+ &__img {
9
+ display: block;
10
+ width: 100%;
11
+ height: 100%;
12
+ object-fit: cover;
13
+ }
14
+
15
+ &__fallback {
16
+ display: flex;
17
+ align-items: center;
18
+ justify-content: center;
19
+ width: 100%;
20
+ height: 100%;
21
+ color: var(--smui-onSurfaceColor);
22
+ background-color: var(--smui-surfaceVariant);
23
+ }
24
+ }
@@ -0,0 +1,2 @@
1
+ @import (reference) "../../_prelude.less";
2
+ @import "./overflowMenu.less";
@@ -0,0 +1,7 @@
1
+ .smwb-overflow-menu {
2
+ display: inline-flex;
3
+
4
+ &__item--danger {
5
+ color: var(--smui-errorColor);
6
+ }
7
+ }
@@ -0,0 +1,2 @@
1
+ @import (reference) "../../_prelude.less";
2
+ @import "./saveAssetDialog.less";
@@ -0,0 +1,23 @@
1
+ .smwb-save-asset-dialog {
2
+ &__body {
3
+ display: flex;
4
+ flex-direction: column;
5
+ gap: 12px;
6
+ min-width: 280px;
7
+ }
8
+
9
+ &__preview {
10
+ display: flex;
11
+ justify-content: center;
12
+ align-items: center;
13
+ border-radius: 8px;
14
+ overflow: hidden;
15
+ background-color: var(--smui-surfaceVariant);
16
+
17
+ img {
18
+ max-width: 100%;
19
+ max-height: 200px;
20
+ object-fit: contain;
21
+ }
22
+ }
23
+ }
@@ -0,0 +1,2 @@
1
+ @import (reference) "../../_prelude.less";
2
+ @import "./thumbCard.less";
@@ -0,0 +1,77 @@
1
+ .smwb-thumb-card {
2
+ position: relative;
3
+ display: flex;
4
+ flex-direction: column;
5
+ border-radius: 8px;
6
+ overflow: visible;
7
+ outline: none;
8
+
9
+ &--interactive {
10
+ cursor: pointer;
11
+ }
12
+
13
+ &--disabled {
14
+ opacity: 0.5;
15
+ pointer-events: none;
16
+ }
17
+
18
+ &__media {
19
+ position: relative;
20
+ width: 100%;
21
+ aspect-ratio: 1;
22
+ border-radius: 8px;
23
+ overflow: hidden;
24
+ background-color: var(--smui-surfaceVariant);
25
+ }
26
+
27
+ &--selected &__media {
28
+ outline: 2px solid var(--smui-primaryColor);
29
+ outline-offset: 1px;
30
+ }
31
+
32
+ &--interactive:focus-visible &__media {
33
+ outline: 2px solid var(--smui-primaryColor);
34
+ outline-offset: 1px;
35
+ }
36
+
37
+ &__slot {
38
+ position: absolute;
39
+ top: 4px;
40
+ display: flex;
41
+ gap: 4px;
42
+ z-index: 1;
43
+
44
+ &--start {
45
+ left: 4px;
46
+ }
47
+
48
+ &--end {
49
+ right: 4px;
50
+ }
51
+ }
52
+
53
+ &__caption {
54
+ margin-top: 4px;
55
+ font-size: 0.8125rem;
56
+ color: var(--smui-onSurfaceColor);
57
+ white-space: nowrap;
58
+ overflow: hidden;
59
+ text-overflow: ellipsis;
60
+ }
61
+
62
+ &__preview {
63
+ z-index: 1000;
64
+ border-radius: 8px;
65
+ overflow: hidden;
66
+ box-shadow: 0 8px 24px rgb(0 0 0 / 30%);
67
+ background-color: var(--smui-surfaceBackground);
68
+ pointer-events: none;
69
+
70
+ img {
71
+ display: block;
72
+ max-width: 320px;
73
+ max-height: 320px;
74
+ object-fit: contain;
75
+ }
76
+ }
77
+ }
@@ -0,0 +1,2 @@
1
+ @import (reference) "../../_prelude.less";
2
+ @import "./valueSlider.less";
@@ -0,0 +1,51 @@
1
+ .smwb-value-slider {
2
+ display: flex;
3
+ flex-direction: column;
4
+ width: 100%;
5
+
6
+ &__header {
7
+ display: flex;
8
+ align-items: center;
9
+ gap: 8px;
10
+ min-height: 24px;
11
+ }
12
+
13
+ &__label {
14
+ font-size: 0.875rem;
15
+ color: var(--smui-onSurfaceColor);
16
+ }
17
+
18
+ &__spacer {
19
+ flex: 1 1 auto;
20
+ }
21
+
22
+ &__readout {
23
+ font-size: 0.875rem;
24
+ font-variant-numeric: tabular-nums;
25
+ color: var(--smui-onSurfaceColor);
26
+ opacity: 0.85;
27
+ }
28
+
29
+ &__reset {
30
+ display: inline-flex;
31
+ align-items: center;
32
+ justify-content: center;
33
+ padding: 2px;
34
+ border: none;
35
+ background: transparent;
36
+ color: var(--smui-onSurfaceColor);
37
+ cursor: pointer;
38
+ border-radius: 50%;
39
+ opacity: 0.7;
40
+
41
+ &:hover {
42
+ opacity: 1;
43
+ background-color: var(--smui-onSurfaceHover);
44
+ }
45
+
46
+ &:disabled {
47
+ opacity: 0.4;
48
+ cursor: default;
49
+ }
50
+ }
51
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smwb/ui-styles",
3
- "version": "1.0.5",
3
+ "version": "1.1.0",
4
4
  "description": "Framework-agnostic LESS design tokens and component styles (smwb-*) shared by the @smwb UI libraries. Prebuilt aggregate CSS lives in @smwb/ui-css.",
5
5
  "license": "MIT",
6
6
  "sideEffects": [