@dataloop-ai/components 0.16.42 → 0.16.43

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": "@dataloop-ai/components",
3
- "version": "0.16.42",
3
+ "version": "0.16.43",
4
4
  "exports": {
5
5
  ".": "./index.ts",
6
6
  "./models": "./models.ts",
@@ -4,6 +4,7 @@
4
4
  :id="uuid"
5
5
  :tabindex="tabIndex"
6
6
  class="dl-chip"
7
+ :class="chipClass"
7
8
  :style="cssChipVars"
8
9
  >
9
10
  <slot name="prefix" />
@@ -67,13 +68,7 @@ const transformOptions: string[] = [
67
68
  'capitalize',
68
69
  'uppercase',
69
70
  'lowercase',
70
- 'full-width',
71
- 'full-size-kana',
72
- 'inherit',
73
- 'initial',
74
- 'revert',
75
- 'revert-layer',
76
- 'unset'
71
+ 'default'
77
72
  ]
78
73
 
79
74
  export default defineComponent({
@@ -96,7 +91,7 @@ export default defineComponent({
96
91
  tabIndex: { type: [String, Number], default: '' },
97
92
  transform: {
98
93
  type: String,
99
- default: 'lowercase',
94
+ default: 'default',
100
95
  validator: (value: string): boolean =>
101
96
  transformOptions.includes(value)
102
97
  },
@@ -141,6 +136,12 @@ export default defineComponent({
141
136
 
142
137
  return this.iconColor
143
138
  },
139
+ chipClass(): string {
140
+ if (this.transform === 'default') {
141
+ return 'first-letter-capitalized'
142
+ }
143
+ return null
144
+ },
144
145
  cssChipVars(): Record<string, string | number> {
145
146
  return {
146
147
  '--dl-chip-max-width': this.fit
@@ -180,7 +181,9 @@ export default defineComponent({
180
181
  '--dl-chip-left-icon-cursor': this.disabled
181
182
  ? 'not-allowed'
182
183
  : 'pointer',
183
- '--dl-chip-text-transform': this.transform
184
+ '--dl-chip-text-transform': this.chipClass
185
+ ? null
186
+ : this.transform
184
187
  }
185
188
  }
186
189
  },
@@ -213,9 +216,12 @@ export default defineComponent({
213
216
  color: var(--dl-chip-text-color);
214
217
  background-color: var(--dl-chip-bg-color);
215
218
  border: var(--dl-chip-border);
216
- &::first-letter,
217
- & > *::first-letter {
218
- text-transform: capitalize;
219
+
220
+ .first-letter-capitalized {
221
+ &::first-letter,
222
+ & > *::first-letter {
223
+ text-transform: capitalize;
224
+ }
219
225
  }
220
226
 
221
227
  &--content {