@globalbrain/sefirot 2.19.0 → 2.20.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.
@@ -81,7 +81,7 @@ function handleClick(): void {
81
81
  </component>
82
82
  </template>
83
83
 
84
- <style lang="postcss" scoped>
84
+ <style scoped lang="postcss">
85
85
  .SButton {
86
86
  position: relative;
87
87
  display: inline-flex;
@@ -156,7 +156,7 @@ function handleClick(): void {
156
156
  }
157
157
 
158
158
  .SButton.fill {
159
- font-weight: 600;
159
+ font-weight: 500;
160
160
 
161
161
  &.neutral {
162
162
  border-color: var(--button-fill-neutral-border-color);
@@ -1,148 +1,17 @@
1
- <script setup lang="ts">
2
- import { PropType, computed } from 'vue'
3
-
4
- export interface ButtonGroupItem {
5
- label: string
6
- value: string
7
- mode?: Mode
8
- }
9
-
10
- export type Mode = 'neutral' | 'info' | 'success' | 'warning' | 'danger'
11
- export type Size = 'mini' | 'small' | 'medium' | 'large' | 'jumbo'
12
-
13
- const props = defineProps({
14
- items: { type: Array as PropType<ButtonGroupItem[]>, required: true },
15
- size: { type: String as PropType<Size>, default: 'medium' },
16
- modelValue: { type: String, default: null }
17
- })
18
-
19
- const emit = defineEmits(['update:modelValue'])
20
-
21
- const classes = computed(() => [props.size])
22
-
23
- function getButtonClasses(button: ButtonGroupItem) {
24
- return [
25
- { active: button.value === props.modelValue },
26
- button.mode ?? 'neutral'
27
- ]
28
- }
29
-
30
- function handleClick(value: string) {
31
- emit('update:modelValue', value)
32
- }
33
- </script>
34
-
35
1
  <template>
36
- <div class="SButtonGroup" :class="classes">
37
- <button
38
- v-for="item in items"
39
- :key="item.value"
40
- class="button"
41
- :class="getButtonClasses(item)"
42
- @click="handleClick(item.value)"
43
- >
44
- <span class="content">
45
- {{ item.label }}
46
- </span>
47
- </button>
2
+ <div class="SButtonGroup">
3
+ <slot />
48
4
  </div>
49
5
  </template>
50
6
 
51
- <style lang="postcss" scoped>
52
- .SButtonGroup {
53
- display: flex;
54
- width: fit-content;
55
- border: 1px solid var(--c-divider);
56
- border-radius: 4px;
57
- overflow: hidden;
58
- }
59
-
60
- .SButtonGroup.mini {
61
- height: 28px;
62
-
63
- .button {
64
- padding: 0 8px;
65
- height: 28px;
66
- font-size: 12px;
67
- font-weight: 500;
68
- }
69
- }
70
-
71
- .SButtonGroup.small {
72
- height: 32px;
73
-
74
- .button {
75
- padding: 0 10px;
76
- height: 32px;
77
- font-size: 12px;
78
- font-weight: 500;
79
- }
80
- }
81
-
82
- .SButtonGroup.medium {
83
- height: 40px;
84
-
85
- .button {
86
- padding: 0 12px;
87
- height: 40px;
88
- font-size: 13px;
89
- font-weight: 500;
90
- }
91
- }
92
-
93
- .SButtonGroup.large {
94
- height: 48px;
95
-
96
- .button {
97
- padding: 0 14px;
98
- height: 48px;
99
- font-size: 14px;
100
- font-weight: 500;
101
- }
102
- }
103
-
104
- .SButtonGroup.jumbo {
105
- height: 64px;
106
-
107
- .button {
108
- padding: 0 24px;
109
- height: 64px;
110
- font-size: 14px;
111
- font-weight: 500;
112
- }
113
- }
114
-
115
- .button {
116
- border-left: 1px solid transparent;
117
- letter-spacing: .4px;
118
- color: var(--c-text-2);
119
- white-space: nowrap;
120
- transition: color .25s, background-color .25s;
121
-
122
- &:hover {
123
- color: var(--c-text-1);
124
- }
125
- }
126
-
127
- .button:not(:first-child) {
128
- border-left: 1px solid var(--c-divider);
129
- }
130
-
131
- .button.active {
132
- color: var(--c-text-dark-1);
133
- }
7
+ <style scoped lang="postcss">
8
+ .SButtonGroup :slotted(.SButton) {
9
+ border-left-width: 0;
10
+ border-radius: 0;
134
11
 
135
- .button.neutral.active { background-color: var(--c-black); }
136
- .button.info.active { background-color: var(--c-info); }
137
- .button.success.active { background-color: var(--c-success); }
138
- .button.warning.active { background-color: var(--c-warning); }
139
- .button.danger.active { background-color: var(--c-danger); }
12
+ &:first-child { border-left-width: 1px; }
140
13
 
141
- .content {
142
- display: flex;
143
- justify-content: center;
144
- align-items: center;
145
- width: 100%;
146
- height: 100%;
14
+ &:first-child { border-radius: 6px 0 0 6px; }
15
+ &:last-child { border-radius: 0 6px 6px 0; }
147
16
  }
148
17
  </style>
@@ -102,13 +102,12 @@ function handleClick(option: DropdownSectionFilterOption, value: string | number
102
102
  border-radius: 6px;
103
103
  padding: 0 8px;
104
104
  width: 100%;
105
- font-size: 12px;
105
+ font-size: 14px;
106
106
  line-height: 32px;
107
107
  background-color: var(--c-bg);
108
108
  transition: border-color 0.25s;
109
109
 
110
110
  &::placeholder {
111
- font-weight: 500;
112
111
  color: var(--c-text-3);
113
112
  }
114
113
 
@@ -32,7 +32,7 @@ defineProps<{
32
32
  display: inline-block;
33
33
  padding-left: 8px;
34
34
  font-size: 12px;
35
- font-weight: 500;
35
+ font-weight: 400;
36
36
  white-space: nowrap;
37
37
  overflow: hidden;
38
38
  text-overflow: ellipsis;
@@ -22,6 +22,6 @@ defineProps<{
22
22
  display: inline-block;
23
23
  line-height: 20px;
24
24
  font-size: 12px;
25
- font-weight: 500;
25
+ font-weight: 400;
26
26
  }
27
27
  </style>
@@ -29,7 +29,7 @@ defineProps<{
29
29
  text-align: left;
30
30
  line-height: 32px;
31
31
  font-size: 12px;
32
- font-weight: 500;
32
+ font-weight: 400;
33
33
  transition: color 0.25s, background-color 0.25s;
34
34
 
35
35
  &:hover {
@@ -114,7 +114,6 @@ function getErrorMsg(validation: Validatable) {
114
114
  align-items: baseline;
115
115
  width: 100%;
116
116
  line-height: 16px;
117
- font-weight: 500;
118
117
  cursor: pointer;
119
118
  transition: color 0.25s;
120
119
  }
@@ -126,6 +125,7 @@ function getErrorMsg(validation: Validatable) {
126
125
  }
127
126
 
128
127
  .label-text-value {
128
+ font-weight: 500;
129
129
  color: var(--input-label-color);
130
130
  }
131
131
 
@@ -144,7 +144,7 @@ function getErrorMsg(validation: Validatable) {
144
144
  display: inline-block;
145
145
  margin-left: 8px;
146
146
  font-size: 12px;
147
- font-weight: 500;
147
+ font-weight: 400;
148
148
  color: var(--c-text-2);
149
149
  }
150
150
 
@@ -158,7 +158,7 @@ function getErrorMsg(validation: Validatable) {
158
158
  padding: 6px 0 0 0;
159
159
  line-height: 18px;
160
160
  font-size: 12px;
161
- font-weight: 500;
161
+ font-weight: 400;
162
162
  color: var(--input-error-text-color);
163
163
  transition: opacity 0.25s, transform 0.25s;
164
164
  }
@@ -168,7 +168,7 @@ function getErrorMsg(validation: Validatable) {
168
168
  padding: 4px 0 0;
169
169
  line-height: 20px;
170
170
  font-size: 12px;
171
- font-weight: 500;
171
+ font-weight: 400;
172
172
  color: var(--c-text-2);
173
173
  }
174
174
 
@@ -123,6 +123,6 @@ function onClick() {
123
123
  padding-left: 10px;
124
124
  line-height: 20px;
125
125
  font-size: 14px;
126
- font-weight: 500;
126
+ font-weight: 400;
127
127
  }
128
128
  </style>
@@ -53,7 +53,7 @@ function onClick() {
53
53
  display: inline-block;
54
54
  border: 1px solid transparent;
55
55
  letter-spacing: 0.4px;
56
- font-weight: 600;
56
+ font-weight: 500;
57
57
  transition: border-color 0.25s, color 0.25s, background-color 0.25s;
58
58
  }
59
59
 
@@ -9,17 +9,11 @@ body {
9
9
  min-width: 320px;
10
10
  min-height: 100vh;
11
11
  font-family: var(--font-family-base);
12
- letter-spacing: .4px;
13
12
  line-height: 24px;
14
13
  font-size: 16px;
15
14
  font-weight: 400;
16
15
  color: var(--c-text-1);
17
16
  background-color: var(--c-bg);
18
- direction: ltr;
19
- font-synthesis: none;
20
- text-rendering: optimizeLegibility;
21
- -webkit-font-smoothing: antialiased;
22
- -moz-osx-font-smoothing: grayscale;
23
17
  }
24
18
 
25
19
  blockquote,
@@ -103,7 +97,6 @@ iframe,
103
97
  embed,
104
98
  object {
105
99
  display: block;
106
- vertical-align: middle;
107
100
  }
108
101
 
109
102
  img,
@@ -119,6 +112,7 @@ select,
119
112
  textarea {
120
113
  border: 0;
121
114
  padding: 0;
115
+ letter-spacing: inherit;
122
116
  line-height: inherit;
123
117
  color: inherit;
124
118
  }
@@ -171,17 +165,20 @@ textarea {
171
165
 
172
166
  input[type="number"] {
173
167
  -moz-appearance: textfield;
168
+ appearance: textfield;
174
169
  }
175
170
 
176
171
  input[type="number"]::-webkit-outer-spin-button,
177
172
  input[type="number"]::-webkit-inner-spin-button {
178
- -webkit-appearance: none;
179
173
  margin: 0;
174
+ -webkit-appearance: none;
175
+ appearance: none;
180
176
  }
181
177
 
182
178
  input[type="select"],
183
179
  select {
184
180
  -webkit-appearance: none;
181
+ appearance: none;
185
182
  }
186
183
 
187
184
  fieldset {
@@ -58,8 +58,8 @@
58
58
  --c-neutral-dark-dimm-2: rgba(255, 255, 255, 0.24);
59
59
 
60
60
  --c-text-light-1: #1f1f1f;
61
- --c-text-light-2: rgba(60, 60, 67, 0.6);
62
- --c-text-light-3: rgba(60, 60, 67, 0.3);
61
+ --c-text-light-2: rgba(60, 60, 67, 0.72);
62
+ --c-text-light-3: rgba(60, 60, 67, 0.39);
63
63
 
64
64
  --c-text-dark-1: rgba(235, 235, 245, 0.98);
65
65
  --c-text-dark-2: rgba(235, 235, 245, 0.6);
@@ -198,6 +198,8 @@
198
198
  --c-text-inverse-2: var(--c-text-dark-2);
199
199
  --c-text-inverse-3: var(--c-text-dark-3);
200
200
 
201
+ --c-soft: var(--c-white-soft);
202
+
201
203
  --c-mute: #f1f1f1;
202
204
  --c-mute-light: #f9f9f9;
203
205
  --c-mute-lighter: #ffffff;
@@ -251,6 +253,8 @@
251
253
  --c-text-inverse-2: var(--c-text-light-2);
252
254
  --c-text-inverse-3: var(--c-text-light-3);
253
255
 
256
+ --c-soft: #222226;
257
+
254
258
  --c-mute: #2c2c2e;
255
259
  --c-mute-light: #3a3a3c;
256
260
  --c-mute-lighter: #505053;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@globalbrain/sefirot",
3
- "version": "2.19.0",
3
+ "version": "2.20.0",
4
4
  "packageManager": "pnpm@7.26.2",
5
5
  "description": "Vue Components for Global Brain Design System.",
6
6
  "author": "Kia Ishii <ka.ishii@globalbrains.com>",