@dataloop-ai/components 0.20.268 → 0.20.269

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.20.268",
3
+ "version": "0.20.269",
4
4
  "exports": {
5
5
  ".": "./index.ts",
6
6
  "./models": "./models.ts",
@@ -23,20 +23,12 @@
23
23
  </p>
24
24
  </div>
25
25
  <div class="actions-container">
26
- <slot name="actions" />
26
+ <slot name="actions" :button-props="actionButtonProps" />
27
27
  <dl-button
28
28
  v-if="closeButton"
29
29
  class="close-button"
30
+ v-bind="actionButtonProps"
30
31
  icon="icon-dl-close"
31
- icon-size="16px"
32
- flat
33
- size="m"
34
- text-color="var(--dell-gray-600)"
35
- hover-bg-color="var(--dell-gray-100)"
36
- pressed-bg-color="var(--dell-gray-200)"
37
- hover-text-color="var(--dell-gray-800)"
38
- pressed-text-color="var(--dell-gray-800)"
39
- :padding="closeIconSizePadding"
40
32
  @click="$emit('onClose')"
41
33
  >
42
34
  <dl-tooltip :delay="800"> Close </dl-tooltip>
@@ -69,8 +61,19 @@ export default defineComponent({
69
61
  setup(props, { slots }) {
70
62
  const hasTitle = computed(() => !!props.title || !!slots.title)
71
63
  const hasSubtitle = computed(() => !!props.subtitle || !!slots.subtitle)
72
- const closeIconSizePadding = `4px`
73
- return { hasTitle, hasSubtitle, closeIconSizePadding }
64
+ const actionButtonProps = {
65
+ iconSize: '16px',
66
+ flat: true,
67
+ size: 'm',
68
+ textColor: 'var(--dell-gray-600)',
69
+ hoverBgColor: 'var(--dell-gray-100)',
70
+ pressedBgColor: 'var(--dell-gray-200)',
71
+ hoverTextColor: 'var(--dell-gray-800)',
72
+ pressedTextColor: 'var(--dell-gray-800)',
73
+ padding: '4px'
74
+ }
75
+
76
+ return { hasTitle, hasSubtitle, actionButtonProps }
74
77
  }
75
78
  })
76
79
  </script>
@@ -106,7 +109,7 @@ export default defineComponent({
106
109
  display: flex;
107
110
  gap: var(--dl-dialog-box-header-actions-gap, 4px);
108
111
  align-items: flex-start;
109
- .close-button ::v-deep button.dl-button {
112
+ ::v-deep button.dl-button {
110
113
  --dl-button-border-radius: 0;
111
114
  border: none;
112
115
  --dl-button-border: none;
@@ -17,54 +17,16 @@
17
17
  subtitle="updated by rotemshaham@dataloop.ai"
18
18
  @on-close="closeModal"
19
19
  >
20
- <template #actions>
21
- <dl-button
22
- icon="icon-dl-edit"
23
- icon-size="16px"
24
- size="m"
25
- flat
26
- text-color="var(--dell-gray-600)"
27
- hover-bg-color="var(--dell-gray-100)"
28
- pressed-bg-color="var(--dell-gray-200)"
29
- hover-text-color="var(--dell-gray-800)"
30
- pressed-text-color="var(--dell-gray-800)"
31
- padding="0 0 0 0"
32
- />
33
- <dl-button
34
- icon="icon-dl-delete"
35
- icon-size="16px"
36
- size="m"
37
- flat
38
- text-color="var(--dell-gray-600)"
39
- hover-bg-color="var(--dell-gray-100)"
40
- pressed-bg-color="var(--dell-gray-200)"
41
- hover-text-color="var(--dell-gray-800)"
42
- pressed-text-color="var(--dell-gray-800)"
43
- padding="0 0 0 0"
44
- />
20
+ <template #actions="{ buttonProps }">
21
+ <dl-button v-bind="buttonProps" icon="icon-dl-edit" />
22
+ <dl-button v-bind="buttonProps" icon="icon-dl-delete" />
45
23
  <dl-button
24
+ v-bind="buttonProps"
46
25
  icon="icon-dl-download"
47
- icon-size="16px"
48
- size="m"
49
- flat
50
- text-color="var(--dell-gray-600)"
51
- hover-bg-color="var(--dell-gray-100)"
52
- pressed-bg-color="var(--dell-gray-200)"
53
- hover-text-color="var(--dell-gray-800)"
54
- pressed-text-color="var(--dell-gray-800)"
55
- padding="0 0 0 0"
56
26
  />
57
27
  <dl-button
28
+ v-bind="buttonProps"
58
29
  icon="icon-dl-settings"
59
- icon-size="16px"
60
- size="m"
61
- flat
62
- text-color="var(--dell-gray-600)"
63
- hover-bg-color="var(--dell-gray-100)"
64
- pressed-bg-color="var(--dell-gray-200)"
65
- hover-text-color="var(--dell-gray-800)"
66
- pressed-text-color="var(--dell-gray-800)"
67
- padding="0 0 0 0"
68
30
  />
69
31
  </template>
70
32
  </dl-dialog-box-header>