@hyvor/design 2.1.18 → 2.1.19

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.
@@ -80,133 +80,155 @@
80
80
  {/if}
81
81
  </svelte:element>
82
82
 
83
- <style>span {
84
- vertical-align: middle;
85
- border-radius: 20px;
86
- display: inline-flex;
87
- align-items: center;
88
- }
89
-
90
- span.has-start :global(> *:first-child) {
91
- margin-right: 5px;
92
- }
93
-
94
- span.has-end :global(> *:last-child) {
95
- margin-left: 5px;
96
- }
97
-
98
- span.size-x-small {
99
- font-size: 10px;
100
- padding: 2px 7px;
101
- }
102
-
103
- span.size-small {
104
- font-size: 12px;
105
- padding: 2px 9px;
106
- }
107
-
108
- span.size-medium {
109
- font-size: 14px;
110
- padding: 3px 12px;
111
- }
112
-
113
- span.size-large {
114
- font-size: 16px;
115
- padding: 4px 16px;
116
- }
117
-
118
- span.interactive {
119
- cursor: pointer;
120
- transition: opacity 0.1s;
121
- }
122
-
123
- span.interactive:hover {
124
- opacity: 0.7;
125
- }
126
-
127
- span.style-default.color-default {
128
- background-color: var(--gray-light);
129
- color: var(--gray-dark);
130
- }
131
- span.style-default.color-accent {
132
- background-color: var(--accent-light);
133
- color: var(--accent);
134
- }
135
- span.style-default.color-green {
136
- background-color: var(--green-light);
137
- color: var(--green-dark);
138
- }
139
- span.style-default.color-red {
140
- background-color: var(--red-light);
141
- color: var(--red-dark);
142
- }
143
- span.style-default.color-blue {
144
- background-color: var(--blue-light);
145
- color: var(--blue-dark);
146
- }
147
- span.style-default.color-orange {
148
- background-color: var(--orange-light);
149
- color: var(--orange-dark);
150
- }
151
-
152
- span.style-outline.color-default {
153
- color: var(--gray-dark);
154
- border: 1px solid var(--gray-dark);
155
- }
156
- span.style-outline.color-accent {
157
- color: var(--accent);
158
- border: 1px solid var(--accent);
159
- }
160
- span.style-outline.color-green {
161
- color: var(--green-dark);
162
- border: 1px solid var(--green-dark);
163
- }
164
- span.style-outline.color-red {
165
- color: var(--red-dark);
166
- border: 1px solid var(--red-dark);
167
- }
168
- span.style-outline.color-blue {
169
- color: var(--blue-dark);
170
- border: 1px solid var(--blue-dark);
171
- }
172
- span.style-outline.color-orange {
173
- color: var(--orange-dark);
174
- border: 1px solid var(--orange-dark);
175
- }
176
-
177
- span.style-outline-fill.color-default {
178
- background-color: var(--gray-light);
179
- color: var(--gray-dark);
180
- border: 1px solid var(--gray);
181
- }
182
- span.style-outline-fill.color-accent {
183
- background-color: var(--accent-light);
184
- color: var(--accent);
185
- border: 1px solid var(--accent);
186
- }
187
- span.style-outline-fill.color-green {
188
- background-color: var(--green-light);
189
- color: var(--green-dark);
190
- border: 1px solid var(--green-dark);
191
- }
192
- span.style-outline-fill.color-red {
193
- background-color: var(--red-light);
194
- color: var(--red-dark);
195
- border: 1px solid var(--red-dark);
196
- }
197
- span.style-outline-fill.color-blue {
198
- background-color: var(--blue-light);
199
- color: var(--blue-dark);
200
- border: 1px solid var(--blue-dark);
201
- }
202
- span.style-outline-fill.color-orange {
203
- background-color: var(--orange-light);
204
- color: var(--orange-dark);
205
- border: 1px solid var(--orange-dark);
206
- }
207
-
208
- .button[disabled] {
209
- opacity: 0.5 !important;
210
- cursor: not-allowed;
211
- box-shadow: none !important;
212
- }</style>
83
+ <style>
84
+ span {
85
+ vertical-align: middle;
86
+ border-radius: 20px;
87
+ display: inline-flex;
88
+ align-items: center;
89
+ }
90
+
91
+ span.has-start :global(> *:first-child) {
92
+ margin-right: 5px;
93
+ }
94
+
95
+ span.has-end :global(> *:last-child) {
96
+ margin-left: 5px;
97
+ }
98
+
99
+ span.size-x-small {
100
+ font-size: 10px;
101
+ padding: 2px 7px;
102
+ }
103
+
104
+ span.size-small {
105
+ font-size: 12px;
106
+ padding: 2px 9px;
107
+ }
108
+
109
+ span.size-medium {
110
+ font-size: 14px;
111
+ padding: 3px 12px;
112
+ }
113
+
114
+ span.size-large {
115
+ font-size: 16px;
116
+ padding: 4px 16px;
117
+ }
118
+
119
+ span.interactive {
120
+ cursor: pointer;
121
+ transition: opacity 0.1s;
122
+ }
123
+ span.interactive:hover {
124
+ opacity: 0.7;
125
+ }
126
+
127
+ span.style-default {
128
+ &.color-default {
129
+ background-color: var(--gray-light);
130
+ color: var(--gray-dark);
131
+ }
132
+
133
+ &.color-accent {
134
+ background-color: var(--accent-light);
135
+ color: var(--accent);
136
+ }
137
+
138
+ &.color-green {
139
+ background-color: var(--green-light);
140
+ color: var(--green-dark);
141
+ }
142
+
143
+ &.color-red {
144
+ background-color: var(--red-light);
145
+ color: var(--red-dark);
146
+ }
147
+
148
+ &.color-blue {
149
+ background-color: var(--blue-light);
150
+ color: var(--blue-dark);
151
+ }
152
+
153
+ &.color-orange {
154
+ background-color: var(--orange-light);
155
+ color: var(--orange-dark);
156
+ }
157
+ }
158
+
159
+ span.style-outline {
160
+ &.color-default {
161
+ color: var(--gray-dark);
162
+ border: 1px solid var(--gray-dark);
163
+ }
164
+
165
+ &.color-accent {
166
+ color: var(--accent);
167
+ border: 1px solid var(--accent);
168
+ }
169
+
170
+ &.color-green {
171
+ color: var(--green-dark);
172
+ border: 1px solid var(--green-dark);
173
+ }
174
+
175
+ &.color-red {
176
+ color: var(--red-dark);
177
+ border: 1px solid var(--red-dark);
178
+ }
179
+
180
+ &.color-blue {
181
+ color: var(--blue-dark);
182
+ border: 1px solid var(--blue-dark);
183
+ }
184
+
185
+ &.color-orange {
186
+ color: var(--orange-dark);
187
+ border: 1px solid var(--orange-dark);
188
+ }
189
+ }
190
+
191
+ span.style-outline-fill {
192
+ &.color-default {
193
+ background-color: var(--gray-light);
194
+ color: var(--gray-dark);
195
+ border: 1px solid var(--gray);
196
+ }
197
+
198
+ &.color-accent {
199
+ background-color: var(--accent-light);
200
+ color: var(--accent);
201
+ border: 1px solid var(--accent);
202
+ }
203
+
204
+ &.color-green {
205
+ background-color: var(--green-light);
206
+ color: var(--green-dark);
207
+ border: 1px solid var(--green-dark);
208
+ }
209
+
210
+ &.color-red {
211
+ background-color: var(--red-light);
212
+ color: var(--red-dark);
213
+ border: 1px solid var(--red-dark);
214
+ }
215
+
216
+ &.color-blue {
217
+ background-color: var(--blue-light);
218
+ color: var(--blue-dark);
219
+ border: 1px solid var(--blue-dark);
220
+ }
221
+
222
+ &.color-orange {
223
+ background-color: var(--orange-light);
224
+ color: var(--orange-dark);
225
+ border: 1px solid var(--orange-dark);
226
+ }
227
+ }
228
+
229
+ .button[disabled] {
230
+ opacity: 0.5 !important;
231
+ cursor: not-allowed;
232
+ box-shadow: none !important;
233
+ }
234
+ </style>
@@ -89,92 +89,93 @@
89
89
  {/if}
90
90
  </label>
91
91
 
92
- <style>.slot {
93
- display: inline-flex;
94
- align-items: center;
95
- color: var(--text-light);
96
- }
97
- .slot.start {
98
- margin-right: 8px;
99
- }
100
- .slot.end {
101
- margin-left: 8px;
102
- }
103
-
104
- .input-wrap {
105
- display: inline-flex;
106
- align-items: center;
107
- height: 30px;
108
- padding: 0 15px;
109
- border-radius: 20px;
110
- background: var(--input);
111
- transition: 0.2s box-shadow;
112
- font-size: 14px;
113
- --local-shadow-size: 2px;
114
- }
115
- .input-wrap:focus-within {
116
- outline: 0;
117
- box-shadow: 0 0 0 var(--local-shadow-size) var(--accent-light);
118
- }
119
-
120
- .input-wrap.block {
121
- display: flex;
122
- width: 100%;
123
- }
124
-
125
- input {
126
- flex: 1;
127
- width: 100%;
128
- border: none;
129
- font-family: inherit;
130
- font-size: inherit;
131
- background: transparent;
132
- padding: 0;
133
- margin: 0;
134
- color: inherit;
135
- height: 100%;
136
- }
137
- input:focus {
138
- outline: none;
139
- }
140
-
141
- .input-wrap.size-x-small {
142
- padding: 0 15px;
143
- height: 20px;
144
- font-size: 12px;
145
- --local-shadow-size: 1px;
146
- }
147
-
148
- .input-wrap.size-small {
149
- padding: 0 15px;
150
- height: 26px;
151
- font-size: 12px;
152
- --local-shadow-size: 1px;
153
- }
154
-
155
- .input-wrap.size-large {
156
- padding: 0 20px;
157
- height: 36px;
158
- font-size: 16px;
159
- }
160
-
161
- .input-wrap.state-error {
162
- box-shadow: 0 0 0 var(--local-shadow-size) var(--red-light);
163
- }
164
- .input-wrap.state-error:focus-within {
165
- box-shadow: 0 0 0 calc(var(--local-shadow-size) + 1px) var(--red-light);
166
- }
167
-
168
- .input-wrap.state-success {
169
- box-shadow: 0 0 0 2px var(--green-light);
170
- }
171
- .input-wrap.state-success:focus-within {
172
- box-shadow: 0 0 0 calc(var(--local-shadow-size) + 1px) var(--green-light);
173
- }
174
-
175
- .input-wrap.state-warning {
176
- box-shadow: 0 0 0 2px var(--orange-light);
177
- }
178
- .input-wrap.state-warning:focus-within {
179
- box-shadow: 0 0 0 calc(var(--local-shadow-size) + 1px) var(--orange-light);
180
- }</style>
92
+ <style>
93
+ .slot {
94
+ display: inline-flex;
95
+ align-items: center;
96
+ color: var(--text-light);
97
+ &.start {
98
+ margin-right: 8px;
99
+ }
100
+ &.end {
101
+ margin-left: 8px;
102
+ }
103
+ }
104
+
105
+ .input-wrap {
106
+ display: inline-flex;
107
+ align-items: center;
108
+ height: 30px;
109
+ padding: 0 15px;
110
+ border-radius: 20px;
111
+ background: var(--input);
112
+ transition: 0.2s box-shadow;
113
+ font-size: 14px;
114
+ --local-shadow-size: 2px;
115
+ &:focus-within {
116
+ outline: 0;
117
+ box-shadow: 0 0 0 var(--local-shadow-size) var(--accent-light);
118
+ }
119
+ }
120
+
121
+ .input-wrap.block {
122
+ display: flex;
123
+ width: 100%;
124
+ }
125
+
126
+ input {
127
+ flex: 1;
128
+ width: 100%;
129
+ border: none;
130
+ font-family: inherit;
131
+ font-size: inherit;
132
+ background: transparent;
133
+ padding: 0;
134
+ margin: 0;
135
+ color: inherit;
136
+ height: 100%;
137
+
138
+ &:focus {
139
+ outline: none;
140
+ }
141
+ }
142
+
143
+ .input-wrap.size-x-small {
144
+ padding: 0 15px;
145
+ height: 20px;
146
+ font-size: 12px;
147
+ --local-shadow-size: 1px;
148
+ }
149
+
150
+ .input-wrap.size-small {
151
+ padding: 0 15px;
152
+ height: 26px;
153
+ font-size: 12px;
154
+ --local-shadow-size: 1px;
155
+ }
156
+
157
+ .input-wrap.size-large {
158
+ padding: 0 20px;
159
+ height: 36px;
160
+ font-size: 16px;
161
+ }
162
+
163
+ .input-wrap.state-error {
164
+ box-shadow: 0 0 0 var(--local-shadow-size) var(--red-light);
165
+ &:focus-within {
166
+ box-shadow: 0 0 0 calc(var(--local-shadow-size) + 1px) var(--red-light);
167
+ }
168
+ }
169
+ .input-wrap.state-success {
170
+ box-shadow: 0 0 0 2px var(--green-light);
171
+ &:focus-within {
172
+ box-shadow: 0 0 0 calc(var(--local-shadow-size) + 1px) var(--green-light);
173
+ }
174
+ }
175
+ .input-wrap.state-warning {
176
+ box-shadow: 0 0 0 2px var(--orange-light);
177
+ &:focus-within {
178
+ box-shadow: 0 0 0 calc(var(--local-shadow-size) + 1px) var(--orange-light);
179
+ }
180
+ }
181
+ </style>
@@ -52,8 +52,7 @@
52
52
  class="state-{state}"
53
53
  {rows}
54
54
  {cols}
55
- {...rest}
56
- ></textarea>
55
+ {...rest}></textarea>
57
56
 
58
57
  {#if end}
59
58
  <span class="slot end">
@@ -80,47 +80,47 @@
80
80
  {/if}
81
81
  </div>
82
82
 
83
- <style>.usage-bar-top {
84
- display: flex;
85
- }
86
-
87
- .usage-name {
88
- flex: 1;
89
- font-size: 14px;
90
- }
91
-
92
- .usage-now {
93
- margin-right: 4px;
94
- font-weight: 600;
95
- }
83
+ <style>
84
+ .usage-bar-top {
85
+ display: flex;
86
+ }
96
87
 
97
- .usage-full {
98
- color: var(--text-light);
99
- font-size: 12px;
100
- }
88
+ .usage-name {
89
+ flex: 1;
90
+ font-size: 14px;
91
+ }
92
+ .usage-now {
93
+ margin-right: 4px;
94
+ font-weight: 600;
95
+ }
101
96
 
102
- .usage-bar-bar {
103
- margin: 6px 0 15px;
104
- width: 100%;
105
- height: 15px;
106
- background: var(--accent-light);
107
- border-radius: 20px;
108
- position: relative;
109
- overflow: hidden;
110
- }
97
+ .usage-full {
98
+ color: var(--text-light);
99
+ font-size: 12px;
100
+ }
111
101
 
112
- .usage-bar-fill {
113
- position: absolute;
114
- left: 0;
115
- top: 0;
116
- height: 100%;
117
- background: var(--accent);
118
- border-radius: 20px;
119
- transition: 0.3s width ease-out;
120
- }
102
+ .usage-bar-bar {
103
+ margin: 6px 0 15px;
104
+ width: 100%;
105
+ height: 15px;
106
+ background: var(--accent-light);
107
+ border-radius: 20px;
108
+ position: relative;
109
+ overflow: hidden;
110
+ }
111
+ .usage-bar-fill {
112
+ position: absolute;
113
+ left: 0;
114
+ top: 0;
115
+ height: 100%;
116
+ background: var(--accent);
117
+ border-radius: 20px;
118
+ transition: 0.3s width ease-out;
119
+ }
121
120
 
122
- .feature-not-included {
123
- color: var(--text-light);
124
- font-size: 12px;
125
- margin: 5px 0 15px;
126
- }</style>
121
+ .feature-not-included {
122
+ color: var(--text-light);
123
+ font-size: 12px;
124
+ margin: 5px 0 15px;
125
+ }
126
+ </style>
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import './variables.scss';
1
+ import './variables.css';
2
2
  import './index.css';
3
3
  import '@fontsource/readex-pro/400.css';
4
4
  import '@fontsource/readex-pro/600.css';
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import './variables.scss';
1
+ import './variables.css';
2
2
  import './index.css';
3
3
  import '@fontsource/readex-pro/400.css';
4
4
  import '@fontsource/readex-pro/600.css';