@thalassic/themes 0.6.0 → 0.8.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.
Files changed (39) hide show
  1. package/package.json +1 -1
  2. package/themes/thalassic/components/_password.scss +18 -0
  3. package/themes/thalassic/components/_pin-input.scss +66 -0
  4. package/themes/thalassic/components/_popover.scss +21 -0
  5. package/themes/thalassic/components/_skeleton.scss +41 -0
  6. package/themes/thalassic/components/_table.scss +78 -0
  7. package/themes/thalassic/components/chart/_chart.scss +19 -0
  8. package/themes/thalassic/components/chart/_index.scss +1 -0
  9. package/themes/thalassic/components/date-time-picker/_calendar.scss +85 -0
  10. package/themes/thalassic/components/date-time-picker/_date-time-picker.scss +63 -0
  11. package/themes/thalassic/components/date-time-picker/_index.scss +5 -0
  12. package/themes/thalassic/components/date-time-picker/_mixins.scss +108 -0
  13. package/themes/thalassic/components/date-time-picker/_month-picker.scss +32 -0
  14. package/themes/thalassic/components/date-time-picker/_time-picker.scss +61 -0
  15. package/themes/thalassic/components/date-time-picker/_year-picker.scss +34 -0
  16. package/themes/thalassic/components/dialog/_dialog-size.scss +29 -0
  17. package/themes/thalassic/components/dialog/_dialog.scss +85 -0
  18. package/themes/thalassic/components/dialog/_index.scss +2 -0
  19. package/themes/thalassic/components/form/_form-control-group.scss +3 -2
  20. package/themes/thalassic/components/form/_form-control.scss +11 -4
  21. package/themes/thalassic/components/index.scss +13 -0
  22. package/themes/thalassic/components/loader/_index.scss +2 -0
  23. package/themes/thalassic/components/loader/_loader-size.scss +26 -0
  24. package/themes/thalassic/components/loader/_loader.scss +25 -0
  25. package/themes/thalassic/components/pagination/_index.scss +2 -0
  26. package/themes/thalassic/components/pagination/_pagination-size.scss +22 -0
  27. package/themes/thalassic/components/pagination/_pagination.scss +79 -0
  28. package/themes/thalassic/components/select/_index.scss +3 -0
  29. package/themes/thalassic/components/select/_select-panel.scss +68 -0
  30. package/themes/thalassic/components/select/_select-size.scss +16 -0
  31. package/themes/thalassic/components/select/_select.scss +94 -0
  32. package/themes/thalassic/components/stepper/_index.scss +3 -0
  33. package/themes/thalassic/components/stepper/_stepper-color.scss +168 -0
  34. package/themes/thalassic/components/stepper/_stepper-orientation.scss +56 -0
  35. package/themes/thalassic/components/stepper/_stepper.scss +144 -0
  36. package/themes/thalassic/components/tooltip/_index.scss +2 -0
  37. package/themes/thalassic/components/tooltip/_tooltip-color.scss +36 -0
  38. package/themes/thalassic/components/tooltip/_tooltip.scss +14 -0
  39. package/themes/thalassic/index.scss +2 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thalassic/themes",
3
- "version": "0.6.0",
3
+ "version": "0.8.0",
4
4
  "license": "MIT",
5
5
  "peerDependencies": {
6
6
  "@angular/common": "^21.0.0",
@@ -0,0 +1,18 @@
1
+ .tls-password {
2
+ display: inline-flex;
3
+
4
+ .tls-password-toggle {
5
+ display: grid;
6
+ align-items: center;
7
+
8
+ &__item {
9
+ grid-area: 1 / 1;
10
+
11
+ text-align: center;
12
+
13
+ &--hidden {
14
+ visibility: hidden;
15
+ }
16
+ }
17
+ }
18
+ }
@@ -0,0 +1,66 @@
1
+ .tls-pin-input {
2
+ --tls-pin-input-size: 40px;
3
+ --tls-pin-input-border-color: var(--color-outline-variant);
4
+ --tls-pin-border-radius: var(--radius-sm);
5
+
6
+ display: inline-flex;
7
+ gap: var(--spacing-1);
8
+
9
+ &__cell {
10
+ width: var(--tls-pin-input-size);
11
+ height: var(--tls-pin-input-size);
12
+
13
+ text-align: center;
14
+
15
+ font-family: inherit;
16
+ font-size: var(--font-label-large-size);
17
+ font-weight: var(--font-label-large-weight);
18
+ line-height: var(--font-label-large-line-height);
19
+ letter-spacing: var(--font-label-large-letter-spacing);
20
+
21
+ background-color: var(--color-surface-container-lowest);
22
+
23
+ border: 1px solid var(--tls-pin-input-border-color);
24
+ border-radius: var(--tls-pin-border-radius);
25
+
26
+ outline: none;
27
+
28
+ transition:
29
+ border-color var(--motion-fast) var(--motion-ease-in-out),
30
+ background-color var(--motion-fast) var(--motion-ease-in-out),
31
+ box-shadow var(--motion-fast) var(--motion-ease-in-out);
32
+
33
+ &:focus {
34
+ border-color: var(--color-primary);
35
+ box-shadow: 0 0 3px -1px var(--color-primary);
36
+
37
+ &::placeholder {
38
+ opacity: 0;
39
+ }
40
+ }
41
+
42
+ &::placeholder {
43
+ color: var(--color-outline);
44
+ }
45
+ }
46
+
47
+ &.tls-pin-input--disabled {
48
+ .tls-pin-input__cell {
49
+ background-color: var(--color-surface-variant);
50
+
51
+ cursor: not-allowed;
52
+ }
53
+ }
54
+
55
+ &:not(.tls-pin-input--disabled).tls-pin-input--touched.tls-pin-input--invalid {
56
+ --tls-pin-input-border-color: var(--color-danger);
57
+
58
+ .tls-pin-input__cell {
59
+ color: var(--color-danger);
60
+
61
+ &::placeholder {
62
+ color: var(--color-danger);
63
+ }
64
+ }
65
+ }
66
+ }
@@ -0,0 +1,21 @@
1
+ .tls-popover {
2
+ --tls-popover-padding: var(--spacing-4);
3
+
4
+ --tls-popover-border-radius: var(--radius-lg);
5
+ --tls-popover-border-width: 1px;
6
+
7
+ --tls-popover-box-shadow: var(--shadow-sm);
8
+ --tls-popover-background-color: var(--color-surface-container-lowest);
9
+ --tls-popover-color: var(--color-on-surface);
10
+ --tls-popover-border-color: var(--color-outline-variant);
11
+
12
+ padding: var(--tls-popover-padding);
13
+
14
+ border-radius: var(--tls-popover-border-radius);
15
+ border: var(--tls-popover-border-width) solid var(--tls-popover-border-color);
16
+
17
+ color: var(--tls-popover-color);
18
+ background-color: var(--tls-popover-background-color);
19
+
20
+ box-shadow: var(--tls-popover-box-shadow);
21
+ }
@@ -0,0 +1,41 @@
1
+ .tls-skeleton {
2
+ --tls-skeleton-color: var(--color-surface-variant);
3
+ --tls-skeleton-shimmer-color: var(--color-surface);
4
+
5
+ display: block;
6
+
7
+ width: var(--tls-skeleton-width);
8
+ height: var(--tls-skeleton-height);
9
+
10
+ border-radius: var(--tls-skeleton-radius);
11
+
12
+ background: linear-gradient(
13
+ 110deg,
14
+ var(--tls-skeleton-color) 25%,
15
+ var(--tls-skeleton-shimmer-color) 50%,
16
+ var(--tls-skeleton-color) 75%
17
+ );
18
+ background-size: 200% 100%;
19
+
20
+ animation: skeleton-shimmer var(--tls-skeleton-duration) linear infinite;
21
+
22
+ &.tls-skeleton--no-animate {
23
+ animation: none;
24
+ background: var(--tls-skeleton-color);
25
+ }
26
+
27
+ @media (prefers-reduced-motion: reduce) {
28
+ animation: none;
29
+ background: var(--tls-skeleton-color);
30
+ }
31
+ }
32
+
33
+ @keyframes skeleton-shimmer {
34
+ from {
35
+ background-position: 200% center;
36
+ }
37
+
38
+ to {
39
+ background-position: -200% center;
40
+ }
41
+ }
@@ -0,0 +1,78 @@
1
+ .tls-table {
2
+ --tls-table-background: var(--color-surface-container-lowest);
3
+ --tls-table-color: var(--color-on-surface);
4
+
5
+ --tls-table-header-background: var(--color-surface-container-lowest);
6
+ --tls-table-header-color: var(--color-on-surface-variant);
7
+ --tls-table-header-weight: var(--font-weight-medium);
8
+
9
+ --tls-table-border-color: var(--color-outline-variant);
10
+
11
+ --tls-table-row-hover-bg: var(--color-surface-container);
12
+ --tls-table-stripe-background: var(--color-surface-container-low);
13
+
14
+ --tls-table-cell-padding-x: var(--spacing-4);
15
+ --tls-table-cell-padding-y: var(--spacing-3);
16
+
17
+ --tls-table-font-size: var(--font-body-medium-size);
18
+ --tls-table-font-weight: var(--font-body-medium-weight);
19
+ --tls-table-line-height: var(--font-body-medium-line-height);
20
+ --tls-table-letter-spacing: var(--font-body-medium-letter-spacing);
21
+
22
+ --tls-table-radius: var(--radius-md);
23
+
24
+ width: 100%;
25
+
26
+ border-collapse: collapse;
27
+ border-radius: var(--tls-table-radius);
28
+ overflow: hidden;
29
+
30
+ font-size: var(--tls-table-font-size);
31
+ font-weight: var(--tls-table-font-weight);
32
+ line-height: var(--tls-table-line-height);
33
+ letter-spacing: var(--tls-table-letter-spacing);
34
+ color: var(--tls-table-color);
35
+
36
+ &__header-row {
37
+ background: var(--tls-table-header-background);
38
+ }
39
+
40
+ &--hide-header &__header-row {
41
+ display: none;
42
+ }
43
+
44
+ &--striped &__row:nth-child(even) &__cell {
45
+ background-color: var(--tls-table-stripe-background);
46
+ }
47
+
48
+ &__header-cell {
49
+ padding: var(--tls-table-cell-padding-y) var(--tls-table-cell-padding-x);
50
+
51
+ color: var(--tls-table-header-color);
52
+
53
+ border-bottom: 1px solid var(--tls-table-border-color);
54
+
55
+ text-align: start;
56
+ font-size: var(--font-label-small-size);
57
+ font-weight: var(--tls-table-header-weight);
58
+ letter-spacing: var(--font-label-small-letter-spacing);
59
+ white-space: nowrap;
60
+ }
61
+
62
+ &__row {
63
+ transition: background var(--motion-fast) var(--motion-ease-in-out);
64
+
65
+ &:not(:last-child) {
66
+ border-bottom: 1px solid var(--tls-table-border-color);
67
+ }
68
+
69
+ &:hover {
70
+ background: var(--tls-table-row-hover-bg);
71
+ }
72
+ }
73
+
74
+ &__cell {
75
+ padding: var(--tls-table-cell-padding-y) var(--tls-table-cell-padding-x);
76
+ background-color: var(--tls-table-background);
77
+ }
78
+ }
@@ -0,0 +1,19 @@
1
+ .tls-chart {
2
+ --tls-chart-x-axis-color: var(--color-outline);
3
+ --tls-chart-x-grid-color: var(--color-outline-variant);
4
+ --tls-chart-x-ticks-color: var(--color-on-surface);
5
+
6
+ --tls-chart-y-axis-color: var(--color-outline);
7
+ --tls-chart-y-grid-color: var(--color-outline-variant);
8
+ --tls-chart-y-ticks-color: var(--color-on-surface);
9
+
10
+ --tls-chart-r-angle-lines-color: var(--color-outline);
11
+ --tls-chart-r-grid-color: var(--color-outline-variant);
12
+ --tls-chart-r-ticks-color: var(--color-on-surface);
13
+ --tls-chart-r-ticks-backdrop-color: var(--color-surface);
14
+ --tls-chart-r-labels-color: var(--color-on-surface);
15
+
16
+ --tls-chart-background-color: transparent;
17
+ --tls-chart-border-color: transparent;
18
+ --tls-chart-color: transparent;
19
+ }
@@ -0,0 +1 @@
1
+ @forward 'chart';
@@ -0,0 +1,85 @@
1
+ @use 'mixins' as picker-mixins;
2
+ @use '../../mixins' as mixins;
3
+
4
+ .tls-calendar {
5
+ display: block;
6
+ width: fit-content;
7
+
8
+ &__header {
9
+ @include picker-mixins.header;
10
+ }
11
+
12
+ &__header-button {
13
+ @include picker-mixins.header-button;
14
+ }
15
+
16
+ &__nav {
17
+ @include picker-mixins.nav;
18
+ }
19
+
20
+ &__grid {
21
+ display: grid;
22
+ grid-template-columns: repeat(7, var(--spacing-9));
23
+ gap: 2px;
24
+ }
25
+
26
+ &__weekday {
27
+ display: flex;
28
+ align-items: center;
29
+ justify-content: center;
30
+
31
+ height: var(--spacing-9);
32
+
33
+ font-size: var(--font-label-medium-size);
34
+ font-weight: var(--font-weight-medium);
35
+ color: var(--color-on-surface-variant);
36
+ }
37
+
38
+ &__day {
39
+ width: var(--spacing-9);
40
+ height: var(--spacing-9);
41
+
42
+ display: flex;
43
+ align-items: center;
44
+ justify-content: center;
45
+
46
+ font-size: var(--font-label-large-size);
47
+
48
+ border: none;
49
+ border-radius: 50%;
50
+
51
+ background: transparent;
52
+ color: var(--color-on-surface);
53
+
54
+ cursor: pointer;
55
+ transition: background-color var(--motion-fast) var(--motion-ease-in-out);
56
+
57
+ &:hover {
58
+ background-color: var(--color-surface-container-high);
59
+ }
60
+
61
+ &:focus-visible {
62
+ @include mixins.focus-ring;
63
+ }
64
+
65
+ &--outside {
66
+ color: var(--color-on-surface-variant);
67
+ opacity: 0.4;
68
+ }
69
+
70
+ &--today {
71
+ color: var(--color-primary);
72
+ font-weight: var(--font-weight-semibold);
73
+ }
74
+
75
+ &--selected {
76
+ background-color: var(--color-primary);
77
+ color: var(--color-on-primary);
78
+
79
+ &:hover {
80
+ background-color: var(--color-primary);
81
+ filter: brightness(0.9);
82
+ }
83
+ }
84
+ }
85
+ }
@@ -0,0 +1,63 @@
1
+ .tls-date-time-picker {
2
+ --tls-date-time-picker-width: 200px;
3
+
4
+ display: inline-block;
5
+
6
+ &__panel {
7
+ padding: var(--spacing-3);
8
+ background-color: var(--color-surface-container-lowest);
9
+ border: 1px solid var(--color-outline-variant);
10
+ border-radius: var(--radius-lg);
11
+ box-shadow: 0 2px 8px rgba(var(--color-shadow), 0.12);
12
+
13
+ &--disabled {
14
+ opacity: 0.5;
15
+ pointer-events: none;
16
+ }
17
+
18
+ &--readonly {
19
+ pointer-events: none;
20
+ }
21
+
22
+ &--invalid {
23
+ border-color: var(--color-danger);
24
+ }
25
+ }
26
+
27
+ &.tls-form-control {
28
+ --tls-form-control-width: var(--tls-date-time-picker-width);
29
+
30
+ display: inline-flex;
31
+ align-items: stretch;
32
+ padding-inline: 0;
33
+
34
+ cursor: pointer;
35
+
36
+ &.tls-form-control--disabled {
37
+ cursor: not-allowed;
38
+ }
39
+
40
+ &:focus-within {
41
+ border: var(--tls-form-control-border-width) solid var(--color-primary);
42
+ box-shadow: 0 0 3px -1px var(--color-primary);
43
+ }
44
+ }
45
+
46
+ &__trigger {
47
+ flex: 1;
48
+
49
+ display: flex;
50
+ align-items: center;
51
+
52
+ padding-inline: var(--tls-form-control-padding-inline);
53
+
54
+ appearance: none;
55
+ outline: none;
56
+ border: none;
57
+ background: transparent;
58
+ color: inherit;
59
+ font: inherit;
60
+
61
+ cursor: inherit;
62
+ }
63
+ }
@@ -0,0 +1,5 @@
1
+ @forward 'calendar';
2
+ @forward 'date-time-picker';
3
+ @forward 'month-picker';
4
+ @forward 'time-picker';
5
+ @forward 'year-picker';
@@ -0,0 +1,108 @@
1
+ @use '../../mixins' as mixins;
2
+
3
+ @mixin header {
4
+ display: flex;
5
+ align-items: center;
6
+ justify-content: space-between;
7
+ margin-bottom: var(--spacing-2);
8
+ }
9
+
10
+ @mixin cell {
11
+ display: flex;
12
+ justify-content: center;
13
+ align-items: center;
14
+
15
+ font-size: var(--font-label-large-size);
16
+
17
+ border-radius: var(--radius-md);
18
+
19
+ color: var(--color-on-surface);
20
+
21
+ cursor: pointer;
22
+ transition: background-color var(--motion-fast) var(--motion-ease-in-out);
23
+
24
+ &:hover {
25
+ background-color: var(--color-surface-container-high);
26
+ }
27
+
28
+ &:focus-visible {
29
+ @include mixins.focus-ring;
30
+ }
31
+
32
+ &--current {
33
+ color: var(--color-primary);
34
+ font-weight: var(--font-weight-medium);
35
+ }
36
+
37
+ &--selected {
38
+ background-color: var(--color-primary);
39
+ color: var(--color-on-primary);
40
+
41
+ &:hover {
42
+ background-color: var(--color-primary);
43
+ filter: brightness(0.9);
44
+ }
45
+ }
46
+ }
47
+
48
+ @mixin header-button {
49
+ align-self: stretch;
50
+
51
+ flex-grow: 1;
52
+ display: flex;
53
+ align-items: center;
54
+ justify-content: center;
55
+
56
+ font-size: var(--font-label-large-size);
57
+ font-weight: var(--font-weight-medium);
58
+ color: var(--color-on-surface);
59
+
60
+ border: none;
61
+ border-radius: var(--radius-sm);
62
+
63
+ background: transparent;
64
+
65
+ cursor: pointer;
66
+
67
+ transition: background-color var(--motion-fast) var(--motion-ease-in-out);
68
+
69
+ &:hover {
70
+ background-color: var(--color-surface-container-high);
71
+ }
72
+
73
+ &:focus-visible {
74
+ @include mixins.focus-ring;
75
+ }
76
+ }
77
+
78
+ @mixin nav {
79
+ width: var(--spacing-7);
80
+ height: var(--spacing-7);
81
+
82
+ display: flex;
83
+ align-items: center;
84
+ justify-content: center;
85
+
86
+ border: none;
87
+ border-radius: var(--radius-sm);
88
+
89
+ background: transparent;
90
+ color: var(--color-on-surface-variant);
91
+
92
+ cursor: pointer;
93
+
94
+ transition: background-color var(--motion-fast) var(--motion-ease-in-out);
95
+
96
+ svg {
97
+ width: 8px;
98
+ height: 14px;
99
+ }
100
+
101
+ &:hover {
102
+ background-color: var(--color-surface-container-high);
103
+ }
104
+
105
+ &:focus-visible {
106
+ @include mixins.focus-ring;
107
+ }
108
+ }
@@ -0,0 +1,32 @@
1
+ @use 'mixins' as picker-mixins;
2
+
3
+ .tls-month-picker {
4
+ --tls-month-picker-cell-height: var(--spacing-10);
5
+
6
+ display: block;
7
+ width: fit-content;
8
+
9
+ &__header {
10
+ @include picker-mixins.header;
11
+ }
12
+
13
+ &__header-button {
14
+ @include picker-mixins.header-button;
15
+ }
16
+
17
+ &__nav {
18
+ @include picker-mixins.nav;
19
+ }
20
+
21
+ &__grid {
22
+ display: grid;
23
+ grid-template-columns: repeat(4, var(--spacing-15));
24
+ gap: var(--spacing-1);
25
+ }
26
+
27
+ &__cell {
28
+ height: var(--tls-month-picker-cell-height);
29
+
30
+ @include picker-mixins.cell;
31
+ }
32
+ }
@@ -0,0 +1,61 @@
1
+ @use '../../mixins' as mixins;
2
+
3
+ .tls-time-picker {
4
+ display: flex;
5
+ justify-content: center;
6
+ align-items: center;
7
+ gap: var(--spacing-1);
8
+
9
+ &__column {
10
+ display: flex;
11
+ flex-direction: column;
12
+ align-items: center;
13
+ gap: var(--spacing-1);
14
+ }
15
+
16
+ &__value {
17
+ font-size: var(--font-title-medium-size);
18
+ font-weight: var(--font-weight-medium);
19
+ color: var(--color-on-surface);
20
+ min-width: var(--spacing-9);
21
+ text-align: center;
22
+ line-height: 1;
23
+ padding: var(--spacing-1) 0;
24
+ }
25
+
26
+ &__separator {
27
+ font-size: var(--font-title-medium-size);
28
+ font-weight: var(--font-weight-medium);
29
+ color: var(--color-on-surface-variant);
30
+ align-self: center;
31
+ padding-bottom: var(--spacing-2);
32
+ }
33
+
34
+ &__arrow {
35
+ display: flex;
36
+ align-items: center;
37
+ justify-content: center;
38
+ width: var(--spacing-7);
39
+ height: var(--spacing-7);
40
+ border: none;
41
+ background: transparent;
42
+ border-radius: 50%;
43
+ cursor: pointer;
44
+ color: var(--color-on-surface-variant);
45
+ transition: background-color var(--motion-fast) var(--motion-ease-in-out);
46
+
47
+ svg {
48
+ width: 14px;
49
+ height: 8px;
50
+ }
51
+
52
+ &:hover {
53
+ background-color: var(--color-surface-container-high);
54
+ color: var(--color-on-surface);
55
+ }
56
+
57
+ &:focus-visible {
58
+ @include mixins.focus-ring;
59
+ }
60
+ }
61
+ }
@@ -0,0 +1,34 @@
1
+ @use 'mixins' as picker-mixins;
2
+
3
+ .tls-year-picker {
4
+ --tls-year-picker-cell-height: var(--spacing-10);
5
+
6
+ display: block;
7
+ width: fit-content;
8
+
9
+ &__header {
10
+ @include picker-mixins.header;
11
+ }
12
+
13
+ &__range {
14
+ font-size: var(--font-label-large-size);
15
+ font-weight: var(--font-weight-medium);
16
+ color: var(--color-on-surface);
17
+ }
18
+
19
+ &__nav {
20
+ @include picker-mixins.nav;
21
+ }
22
+
23
+ &__grid {
24
+ display: grid;
25
+ grid-template-columns: repeat(4, var(--spacing-15));
26
+ gap: var(--spacing-1);
27
+ }
28
+
29
+ &__cell {
30
+ height: var(--tls-year-picker-cell-height);
31
+
32
+ @include picker-mixins.cell;
33
+ }
34
+ }
@@ -0,0 +1,29 @@
1
+ .tls-dialog {
2
+ &.tls-dialog--sm {
3
+ --tls-dialog-width: 400px;
4
+ }
5
+
6
+ &.tls-dialog--md {
7
+ --tls-dialog-width: 560px;
8
+ }
9
+
10
+ &.tls-dialog--lg {
11
+ --tls-dialog-width: 720px;
12
+ }
13
+
14
+ &.tls-dialog--xl {
15
+ --tls-dialog-width: 920px;
16
+ }
17
+
18
+ &.tls-dialog--wide {
19
+ --tls-dialog-width: calc(100svw - var(--spacing-12));
20
+ max-height: calc(100dvh - var(--spacing-12));
21
+ }
22
+
23
+ &.tls-dialog--full {
24
+ --tls-dialog-width: 100svw;
25
+ --tls-dialog-border-radius: 0;
26
+ height: 100dvh;
27
+ max-height: 100dvh;
28
+ }
29
+ }