@dataloop-ai/components 0.17.19 → 0.17.21

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.17.19",
3
+ "version": "0.17.21",
4
4
  "exports": {
5
5
  ".": "./index.ts",
6
6
  "./models": "./models.ts",
@@ -32,6 +32,19 @@ body {
32
32
  }
33
33
  }
34
34
 
35
+ /* Inserting a collapsed row between two flex items will make
36
+ * the flex item that comes after it break to a new row */
37
+ .break {
38
+ flex-basis: 100%;
39
+ height: 0;
40
+ }
41
+
42
+ /* Use a collapsed column to break to a new column */
43
+ .break-column {
44
+ flex-basis: 100%;
45
+ width: 0;
46
+ }
47
+
35
48
  .scroll {
36
49
  overflow: auto;
37
50
  }
@@ -2,6 +2,7 @@
2
2
  <div
3
3
  :id="uuid"
4
4
  :class="rootContainerClasses"
5
+ :style="cssVars"
5
6
  >
6
7
  <div :class="wrapperClasses">
7
8
  <div
@@ -33,9 +34,16 @@
33
34
  </dl-tooltip>
34
35
  </span>
35
36
  </div>
37
+ <div
38
+ v-if="!!topMessage.length && !isSmall"
39
+ class="break"
40
+ />
36
41
  <div
37
42
  v-show="!!topMessage.length"
38
- class="dl-text-input__top-message-container"
43
+ :class="{
44
+ 'dl-text-input__top-message-container': true,
45
+ 'dl-text-input__top-message-container--s': isSmall
46
+ }"
39
47
  >
40
48
  <dl-info-error-message
41
49
  v-show="!!topMessage.length"
@@ -326,7 +334,11 @@ export default defineComponent({
326
334
  type: Boolean,
327
335
  default: false
328
336
  },
329
- fitContent: Boolean
337
+ fitContent: Boolean,
338
+ margin: {
339
+ type: String,
340
+ default: null
341
+ }
330
342
  },
331
343
  emits: ['input', 'focus', 'blur', 'clear', 'enter', 'update:model-value'],
332
344
  setup(props, { emit }) {
@@ -389,6 +401,16 @@ export default defineComponent({
389
401
  }
390
402
  return classes
391
403
  },
404
+ cssVars(): Record<string, any> {
405
+ let inputMargin = this.margin
406
+
407
+ if (!this.margin && this.isSmall) {
408
+ inputMargin = '0px 20px 0px 0px'
409
+ }
410
+ return {
411
+ '--dl-input-margin': inputMargin
412
+ }
413
+ },
392
414
  inputClasses(): string[] {
393
415
  const classes = [
394
416
  'dl-text-input__input',
@@ -616,7 +638,7 @@ export default defineComponent({
616
638
 
617
639
  <style scoped lang="scss">
618
640
  .dl-text-input {
619
- padding: 20px 20px 20px 0px;
641
+ margin: var(--dl-input-margin);
620
642
 
621
643
  /* Chrome, Safari, Edge, Opera */
622
644
  input::-webkit-outer-spin-button,
@@ -670,6 +692,10 @@ export default defineComponent({
670
692
  display: flex;
671
693
  margin-bottom: 10px;
672
694
  text-align: start;
695
+
696
+ &--s {
697
+ padding: 0px 10px;
698
+ }
673
699
  }
674
700
 
675
701
  &__input-wrapper {
@@ -2,9 +2,10 @@
2
2
  <div>
3
3
  <dl-input
4
4
  v-model="textInputValue"
5
- style="width: 220px"
5
+ style="width: 920px"
6
6
  placeholder="Select option"
7
7
  size="l"
8
+ margin="20px"
8
9
  title="Input Title"
9
10
  required
10
11
  tooltip="Quis fugiat et non eu proident sit et amet."