@maalbuquerque/tailsass-ui 1.0.0 → 1.0.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maalbuquerque/tailsass-ui",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "Semantic UI components built on Tailsass utilities.",
5
5
  "main": "dist/tailsass-ui.css",
6
6
  "style": "dist/tailsass-ui.css",
package/src/_button.scss CHANGED
@@ -124,3 +124,51 @@
124
124
  @extend .w-full;
125
125
  }
126
126
  }
127
+
128
+ /**
129
+ * Segmented control / filter group.
130
+ * <div class="btn-group" role="group">
131
+ * <button type="button" class="btn btn-sm btn-secondary is-active">7d</button>
132
+ * <button type="button" class="btn btn-sm btn-secondary">30d</button>
133
+ * </div>
134
+ */
135
+ .btn-group {
136
+ @extend .inline-flex;
137
+ @extend .items-stretch;
138
+ border-radius: var(--ui-radius);
139
+ overflow: hidden;
140
+ border: 1px solid var(--ui-border);
141
+ background: var(--ui-surface);
142
+
143
+ > .btn {
144
+ margin: 0;
145
+ border-radius: 0;
146
+ border-color: transparent;
147
+ border-right: 1px solid var(--ui-border);
148
+ box-shadow: none;
149
+
150
+ &:last-child {
151
+ border-right-width: 0;
152
+ }
153
+
154
+ &:hover {
155
+ z-index: 1;
156
+ }
157
+
158
+ &.is-active,
159
+ &[aria-pressed='true'] {
160
+ background: var(--ui-primary);
161
+ color: var(--ui-primary-text);
162
+ border-color: var(--ui-primary);
163
+ }
164
+
165
+ &.btn-primary.is-active,
166
+ &.btn-secondary.is-active,
167
+ &.btn-ghost.is-active,
168
+ &.btn-outline.is-active {
169
+ background: var(--ui-primary);
170
+ color: var(--ui-primary-text);
171
+ border-color: var(--ui-primary);
172
+ }
173
+ }
174
+ }
@@ -0,0 +1,68 @@
1
+ @use '@maalbuquerque/tailsass/src/index';
2
+ @use 'variables';
3
+
4
+ /**
5
+ * Loading circle.
6
+ * <span class="spinner spinner-md" role="status" aria-label="Loading"></span>
7
+ */
8
+ .spinner {
9
+ @extend .inline-block;
10
+ @extend .shrink-0;
11
+ @extend .rounded-full;
12
+ @extend .border-solid;
13
+ @extend .animate-spin;
14
+ box-sizing: border-box;
15
+ border-color: color-mix(in srgb, var(--ui-primary) 25%, transparent);
16
+ border-top-color: var(--ui-primary);
17
+ vertical-align: middle;
18
+
19
+ &-xs {
20
+ width: 0.75rem;
21
+ height: 0.75rem;
22
+ border-width: 2px;
23
+ }
24
+
25
+ &-sm {
26
+ width: 1rem;
27
+ height: 1rem;
28
+ border-width: 2px;
29
+ }
30
+
31
+ &-md {
32
+ width: 1.5rem;
33
+ height: 1.5rem;
34
+ border-width: 3px;
35
+ }
36
+
37
+ &-lg {
38
+ width: 2rem;
39
+ height: 2rem;
40
+ border-width: 3px;
41
+ }
42
+
43
+ &-xl {
44
+ width: 2.75rem;
45
+ height: 2.75rem;
46
+ border-width: 4px;
47
+ }
48
+
49
+ &-muted {
50
+ border-color: color-mix(in srgb, var(--ui-muted) 30%, transparent);
51
+ border-top-color: var(--ui-muted);
52
+ }
53
+
54
+ &-white {
55
+ border-color: rgb(255 255 255 / 0.3);
56
+ border-top-color: var(--white, #fff);
57
+ }
58
+
59
+ &-danger {
60
+ border-color: color-mix(in srgb, var(--ui-danger) 25%, transparent);
61
+ border-top-color: var(--ui-danger);
62
+ }
63
+
64
+ &-success {
65
+ border-color: color-mix(in srgb, var(--ui-success) 25%, transparent);
66
+ border-top-color: var(--ui-success);
67
+ }
68
+ }
package/src/index.scss CHANGED
@@ -1,5 +1,6 @@
1
1
  @use 'variables';
2
2
  @use 'button';
3
+ @use 'spinner';
3
4
  @use 'form';
4
5
  @use 'card';
5
6
  @use 'dropdown';