@dataloop-ai/components 0.18.37 → 0.18.38

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.18.37",
3
+ "version": "0.18.38",
4
4
  "exports": {
5
5
  ".": "./index.ts",
6
6
  "./models": "./models.ts",
@@ -12,12 +12,7 @@
12
12
  />
13
13
  <div
14
14
  class="dialog-wrapper"
15
- :style="{
16
- width: Number(width) ? `${width}px` : width,
17
- height: Number(height) ? `${height}px` : height,
18
- transform: `translate(${draggableOptions.draggableX}px, ${draggableOptions.draggableY}px)`,
19
- maxHeight: !fullscreen && !fullHeight ? '90vh' : ''
20
- }"
15
+ :style="wrapperStyles"
21
16
  :class="{
22
17
  'dialog-wrapper--fullscreen': fullscreen,
23
18
  'dialog-wrapper--fullheight': fullHeight,
@@ -164,6 +159,21 @@ export default defineComponent({
164
159
  `${this.zIndex}` ?? 'var(--dl-z-index-dialog)'
165
160
  }
166
161
  },
162
+ wrapperStyles() {
163
+ return {
164
+ ...{
165
+ width: Number(this.width) ? `${this.width}px` : this.width,
166
+ height: Number(this.height)
167
+ ? `${this.height}px`
168
+ : this.height,
169
+ maxHeight:
170
+ !this.fullscreen && !this.fullHeight ? '90vh' : ''
171
+ },
172
+ ...(this.draggable && {
173
+ transform: `translate(${this.draggableOptions.draggableX}px, ${this.draggableOptions.draggableY}px)`
174
+ })
175
+ }
176
+ },
167
177
  iconStyles(): Record<string, string> {
168
178
  return {
169
179
  cursor: this.draggableOptions.draggableCursor,
@@ -27,21 +27,38 @@
27
27
  icon="icon-dl-search"
28
28
  @click.stop="onClick"
29
29
  />
30
+
31
+ <dl-input
32
+ v-model="inputValue"
33
+ style="margin-top: 10px"
34
+ title="Custom Label"
35
+ />
36
+ <DlIcon
37
+ size="50px"
38
+ :icon="inputValue"
39
+ />
30
40
  </div>
31
41
  </template>
32
42
 
33
43
  <script lang="ts">
34
- import { defineComponent } from 'vue-demi'
35
- import { DlIcon } from '../components'
44
+ import { defineComponent, ref } from 'vue-demi'
45
+ import { DlIcon, DlInput } from '../components'
36
46
  export default defineComponent({
37
47
  name: 'DlIconDemo',
38
48
  components: {
39
- DlIcon
49
+ DlIcon,
50
+ DlInput
40
51
  },
41
- methods: {
42
- onClick() {
52
+ setup() {
53
+ const inputValue = ref('icon-dl-search')
54
+
55
+ const onClick = () => {
43
56
  console.log('clicked')
44
57
  }
58
+ return {
59
+ onClick,
60
+ inputValue
61
+ }
45
62
  }
46
63
  })
47
64
  </script>