bfg-common 1.5.293 → 1.5.294

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.
Files changed (136) hide show
  1. package/CODE_STYLE.md +109 -109
  2. package/assets/img/icons/icons-sprite-dark-3.svg +227 -227
  3. package/assets/img/icons/icons-sprite-dark-5.svg +488 -488
  4. package/assets/img/icons/icons-sprite-light-3.svg +227 -227
  5. package/assets/img/icons/icons-sprite-light-5.svg +488 -488
  6. package/assets/localization/local_en.json +1 -1
  7. package/components/atoms/TheIcon3.vue +50 -50
  8. package/components/atoms/perPage/PerPage.vue +58 -58
  9. package/components/atoms/table/dataGrid/DataGrid.vue +1717 -1717
  10. package/components/atoms/table/dataGrid/lib/config/settingsTable.ts +94 -94
  11. package/components/atoms/table/dataGrid/lib/utils/export.ts +16 -16
  12. package/components/atoms/tabs/VerticalTabs.vue +105 -105
  13. package/components/common/backup/storage/actions/add/lib/config/steps.ts +168 -168
  14. package/components/common/backup/storage/actions/add/steps/hostAccessibility/HostAccessibility.vue +52 -52
  15. package/components/common/backup/storage/actions/add/steps/nameAndConfigure/NameAndConfigure.vue +42 -42
  16. package/components/common/backup/storage/actions/add/steps/readyComplete/ReadyComplete.vue +45 -45
  17. package/components/common/backup/storage/actions/add/steps/readyComplete/lib/config/propertiesDetails.ts +243 -243
  18. package/components/common/backup/storage/actions/delete/Delete.vue +65 -65
  19. package/components/common/browse/blocks/contents/filesNew/Skeleton.vue +18 -18
  20. package/components/common/context/lib/models/interfaces.ts +31 -31
  21. package/components/common/diagramMain/DiagramMain.vue +897 -897
  22. package/components/common/layout/theHeader/helpMenu/About.vue +82 -82
  23. package/components/common/layout/theHeader/userMenu/modals/preferences/view/ViewOld.vue +112 -112
  24. package/components/common/monitor/overview/OverviewOld.vue +139 -139
  25. package/components/common/pages/home/headline/Headline.vue +45 -45
  26. package/components/common/pages/home/headline/HeadlineOld.vue +42 -42
  27. package/components/common/pages/home/lib/models/interfaces.ts +48 -48
  28. package/components/common/pages/home/widgets/Widgets.vue +49 -49
  29. package/components/common/pages/home/widgets/WidgetsNew.vue +86 -86
  30. package/components/common/pages/home/widgets/WidgetsOld.vue +34 -34
  31. package/components/common/pages/home/widgets/hosts/Hosts.vue +27 -27
  32. package/components/common/pages/home/widgets/hosts/lib/config/items.ts +23 -23
  33. package/components/common/pages/home/widgets/vms/Vms.vue +26 -26
  34. package/components/common/pages/home/widgets/vms/VmsOld.vue +35 -35
  35. package/components/common/pages/home/widgets/vms/lib/config/items.ts +19 -19
  36. package/components/common/pages/packages/Packages.vue +208 -208
  37. package/components/common/pages/shortcuts/block/BlockOld.vue +68 -68
  38. package/components/common/readyToComplete/ReadyToComplete.vue +17 -17
  39. package/components/common/recursionTree/RecursionTree.vue +223 -223
  40. package/components/common/select/button/ButtonDropdown.vue +108 -108
  41. package/components/common/spiceConsole/Drawer.vue +377 -377
  42. package/components/common/spiceConsole/SpiceConsole.vue +127 -127
  43. package/components/common/spiceConsole/lib/models/interfaces.ts +5 -5
  44. package/components/common/vm/actions/add/folderTreeView/FolderTreeView.vue +72 -72
  45. package/components/common/vm/actions/add/folderTreeView/New.vue +40 -40
  46. package/components/common/vm/actions/add/folderTreeView/Old.vue +50 -50
  47. package/components/common/vm/actions/clone/Clone.vue +817 -817
  48. package/components/common/vm/actions/clone/lib/config/steps.ts +291 -291
  49. package/components/common/vm/actions/clone/toTemplate/lib/config/steps.ts +116 -116
  50. package/components/common/vm/actions/common/customizeHardware/virtualHardware/VirtualHardwareOld.vue +321 -321
  51. package/components/common/vm/actions/common/customizeHardware/virtualHardware/browseView/BrowseView.vue +227 -227
  52. package/components/common/vm/actions/common/customizeHardware/virtualHardware/bus/Bus.vue +100 -100
  53. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/CdDvdDrive.vue +232 -232
  54. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/CdDvdDriveNew.vue +3 -3
  55. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/CdDvdDriveOld.vue +168 -168
  56. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/media/Media.vue +25 -25
  57. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/media/MediaNew.vue +78 -78
  58. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/media/MediaOld.vue +50 -50
  59. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/model/ModelNew.vue +26 -24
  60. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/shares/Shares.vue +140 -140
  61. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/shares/lib/config/options.ts +28 -28
  62. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/tooltip/TooltipNew.vue +154 -154
  63. package/components/common/vm/actions/common/customizeHardware/virtualHardware/limit/Limit.vue +220 -220
  64. package/components/common/vm/actions/common/customizeHardware/virtualHardware/memory/Memory.vue +307 -307
  65. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/NewHardDisk.vue +385 -385
  66. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/NewHardDiskNew.vue +3 -3
  67. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/file/FileNew.vue +1 -1
  68. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/location/Location.vue +154 -154
  69. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/location/LocationOld.vue +85 -85
  70. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/maximumSize/MaximumSizeNew.vue +6 -0
  71. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newNetwork/NewNetwork.vue +288 -288
  72. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newNetwork/location/new/table/lib/config/config.ts +94 -94
  73. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newNetwork/macAddress/MacAddress.vue +119 -119
  74. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newNetwork/macAddress/MacAddressNew.vue +1 -1
  75. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/NewPciDevice.vue +205 -205
  76. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/directPathIo/DirectPathIoNew.vue +66 -66
  77. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/directPathIo/DirectPathIoOld.vue +62 -62
  78. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/dynamicDirectPathIo/DynamicDirectPathIo.vue +31 -31
  79. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/dynamicDirectPathIo/DynamicDirectPathIoOld.vue +76 -76
  80. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/note/Note.vue +15 -15
  81. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/note/NoteNew.vue +42 -42
  82. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/note/NoteOld.vue +30 -30
  83. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/nvidiaGrid/NvidiaGridOld.vue +84 -84
  84. package/components/common/vm/actions/common/customizeHardware/virtualHardware/other/Other.vue +16 -16
  85. package/components/common/vm/actions/common/customizeHardware/virtualHardware/other/inputDevices/InputDevicesNew.vue +45 -40
  86. package/components/common/vm/actions/common/customizeHardware/virtualHardware/videoCard/VideoCard.vue +154 -154
  87. package/components/common/vm/actions/common/customizeHardware/virtualHardware/videoCard/numberDisplays/NumberDisplays.vue +53 -53
  88. package/components/common/vm/actions/common/customizeHardware/virtualHardware/videoCard/numberDisplays/NumberDisplaysNew.vue +1 -1
  89. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/delay/Delay.vue +32 -32
  90. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/delay/DelayNew.vue +1 -1
  91. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/firmware/Firmware.vue +60 -60
  92. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/firmware/FirmwareNew.vue +1 -1
  93. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/menu/MenuNew.vue +1 -1
  94. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/order/Order.vue +174 -174
  95. package/components/common/vm/actions/common/customizeHardware/vmoptions/generalOptions/GeneralOptionsNew.vue +3 -3
  96. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/copyPaste/CopyPasteNew.vue +31 -31
  97. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/fileTransfer/FileTransferNew.vue +31 -31
  98. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/folderSharing/FolderSharingNew.vue +1 -1
  99. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/keymap/Keymap.vue +32 -32
  100. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/keymap/KeymapNew.vue +1 -1
  101. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/Password.vue +103 -103
  102. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/PasswordNew.vue +128 -128
  103. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/usbRedirection/UsbRedirection.vue +28 -28
  104. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/usbRedirection/UsbRedirectionNew.vue +1 -1
  105. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/usbRedirection/UsbRedirectionOld.vue +44 -44
  106. package/components/common/vm/actions/common/customizeHardware/vmoptions/tools/ToolsNew.vue +1 -1
  107. package/components/common/vm/actions/common/lib/utils/capabilities.ts +52 -52
  108. package/components/common/vm/actions/common/select/compatibility/Old.vue +107 -107
  109. package/components/common/vm/actions/common/select/computeResource/treeView/TreeView.vue +118 -118
  110. package/components/common/vm/actions/common/select/createType/CreateType.vue +38 -38
  111. package/components/common/vm/actions/common/select/createType/lib/models/interfaces.ts +5 -5
  112. package/components/common/vm/actions/common/select/name/Name.vue +174 -174
  113. package/components/common/vm/actions/common/select/os/Old.vue +152 -152
  114. package/components/common/vm/actions/common/select/os/Os.vue +139 -139
  115. package/components/common/vm/actions/common/select/storage/new/lib/models/interfaces.ts +5 -5
  116. package/components/common/vm/actions/common/select/storage/new/lib/utils/utils.ts +21 -21
  117. package/components/common/vm/actions/editSettings/new/Skeleton.vue +88 -88
  118. package/components/common/vmt/actions/add/Add.vue +641 -641
  119. package/components/common/vmt/actions/add/lib/config/steps.ts +107 -107
  120. package/components/common/vmt/actions/add/lib/models/interfaces.ts +23 -23
  121. package/components/common/wizards/vm/migrate/lib/config/constructDataReady.ts +220 -220
  122. package/components/common/wizards/vm/migrate/lib/config/steps.ts +157 -157
  123. package/components/common/wizards/vm/migrate/lib/validations.ts +68 -68
  124. package/components/common/wizards/vm/migrate/select/network/Network.vue +103 -103
  125. package/components/common/wizards/vm/migrate/select/network/table/network/lib/config/advancedTable.ts +91 -91
  126. package/composables/productNameLocal.ts +30 -30
  127. package/composables/useAppVersion.ts +21 -21
  128. package/package.json +2 -2
  129. package/plugins/date.ts +233 -233
  130. package/plugins/panelStates.ts +70 -70
  131. package/plugins/text.ts +59 -59
  132. package/public/spice-console/lib/images/bitmap.js +203 -203
  133. package/public/spice-console/network/spicechannel.js +387 -387
  134. package/store/main/mutations.ts +7 -7
  135. package/store/main/state.ts +7 -7
  136. package/store/tasks/mappers/recentTasks.ts +64 -64
@@ -1,32 +1,32 @@
1
- <template>
2
- <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-keymap-new
3
- v-if="isNewView"
4
- v-model:keymap="keymap"
5
- :disabled="props.disabled"
6
- :keymap-options="keymapOptions"
7
- />
8
- <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-keymap-old
9
- v-else
10
- v-model:keymap="keymap"
11
- :disabled="props.disabled"
12
- :keymap-options="keymapOptions"
13
- />
14
- </template>
15
-
16
- <script setup lang="ts">
17
- import type { UI_I_OptionItem } from '~/components/atoms/lib/models/interfaces'
18
- import { keymapOptionsConfig } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/keymap/lib/config/config'
19
-
20
- const keymap = defineModel<string>('keymap', { required: true })
21
-
22
- const props = defineProps<{
23
- disabled: boolean
24
- }>()
25
-
26
- const { $store }: any = useNuxtApp()
27
- const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
28
-
29
- const keymapOptions = ref<UI_I_OptionItem[]>(keymapOptionsConfig)
30
- </script>
31
-
32
- <style scoped></style>
1
+ <template>
2
+ <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-keymap-new
3
+ v-if="isNewView"
4
+ v-model:keymap="keymap"
5
+ :disabled="props.disabled"
6
+ :keymap-options="keymapOptions"
7
+ />
8
+ <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-keymap-old
9
+ v-else
10
+ v-model:keymap="keymap"
11
+ :disabled="props.disabled"
12
+ :keymap-options="keymapOptions"
13
+ />
14
+ </template>
15
+
16
+ <script setup lang="ts">
17
+ import type { UI_I_OptionItem } from '~/components/atoms/lib/models/interfaces'
18
+ import { keymapOptionsConfig } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/keymap/lib/config/config'
19
+
20
+ const keymap = defineModel<string>('keymap', { required: true })
21
+
22
+ const props = defineProps<{
23
+ disabled: boolean
24
+ }>()
25
+
26
+ const { $store }: any = useNuxtApp()
27
+ const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
28
+
29
+ const keymapOptions = ref<UI_I_OptionItem[]>(keymapOptionsConfig)
30
+ </script>
31
+
32
+ <style scoped></style>
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <ui-stack-block :has-children="false">
3
3
  <template #stackBlockKey>
4
- {{ localization.common.keymap }}
4
+ <span class="mt-2">{{ localization.common.keymap }}</span>
5
5
  </template>
6
6
  <template #stackBlockContent>
7
7
  <ui-select
@@ -1,103 +1,103 @@
1
- <template>
2
- <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-password-new
3
- v-if="isNewView"
4
- v-model:is-enabled-password="isEnabledPassword"
5
- v-model:form="form"
6
- :disabled="props.disabled"
7
- :error-text="passwordErrorText"
8
- @set-password-disable="setPasswordDisable"
9
- @change-password="changePassword"
10
- @generate-password="onGeneratePassword"
11
- />
12
- <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-password-old
13
- v-else
14
- v-model:is-enabled-password="isEnabledPassword"
15
- v-model:form="form"
16
- :disabled="props.disabled"
17
- :error-text="passwordErrorText"
18
- @set-password-disable="setPasswordDisable"
19
- @change-password="changePassword"
20
- @generate-password="onGeneratePassword"
21
- />
22
- </template>
23
-
24
- <script setup lang="ts">
25
- import type { UI_I_DefaultForm } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/lib/models/interfaces'
26
- import type { UI_I_Localization } from '~/lib/models/interfaces'
27
- import { generatePassword } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/lib/utils'
28
-
29
- const password = defineModel<string>('password', { required: true })
30
-
31
- const props = defineProps<{
32
- disabled: boolean
33
- }>()
34
- const emits = defineEmits<{
35
- (event: 'valid', value: boolean): void
36
- }>()
37
-
38
- const { $store, $validation }: any = useNuxtApp()
39
- const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
40
-
41
- const localization = computed<UI_I_Localization>(() => useLocal())
42
-
43
- const validation = $validation.call({})
44
- const defaultForm: UI_I_DefaultForm = {
45
- password: {
46
- value: password.value,
47
- validations: [
48
- {
49
- value: 'password',
50
- errorText: localization.value.common.passwordsMustLeast8CharactersLongContainUpperAndLowerCaseLetterNumberAndSpecialCharacter,
51
- },
52
- ],
53
- },
54
- }
55
- const form = ref<UI_I_DefaultForm>(useDeepCopy(defaultForm))
56
- const setForm = (): void => {
57
- form.value = useDeepCopy(defaultForm)
58
- validation.setForm(form)
59
- }
60
- setForm()
61
-
62
- const showValidationErrors = (): void => {
63
- const valid = validation.touch()
64
- console.log(valid, 111)
65
- passwordErrorText.value = !valid.isValid ? valid.errors.password[0] : ''
66
- emits('valid', valid.isValid)
67
- }
68
- const removeValidationErrors = (): void => {
69
- passwordErrorText.value = ''
70
- emits('valid', true)
71
- }
72
-
73
- const setPasswordDisable = (): void => {
74
- if (isEnabledPassword.value) {
75
- return
76
- }
77
-
78
- removeValidationErrors()
79
- setForm()
80
- password.value = ''
81
- }
82
-
83
- const passwordErrorText = ref<string>('')
84
-
85
- const changePassword = (value: string): void => {
86
- password.value = value
87
-
88
- showValidationErrors()
89
- }
90
-
91
- const isEnabledPassword = ref<boolean>(!!password.value)
92
-
93
- const onGeneratePassword = (): void => {
94
- const generatedPassword = generatePassword()
95
-
96
- form.value.password.value = generatedPassword
97
- password.value = generatedPassword
98
-
99
- showValidationErrors()
100
- }
101
- </script>
102
-
103
- <style scoped></style>
1
+ <template>
2
+ <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-password-new
3
+ v-if="isNewView"
4
+ v-model:is-enabled-password="isEnabledPassword"
5
+ v-model:form="form"
6
+ :disabled="props.disabled"
7
+ :error-text="passwordErrorText"
8
+ @set-password-disable="setPasswordDisable"
9
+ @change-password="changePassword"
10
+ @generate-password="onGeneratePassword"
11
+ />
12
+ <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-password-old
13
+ v-else
14
+ v-model:is-enabled-password="isEnabledPassword"
15
+ v-model:form="form"
16
+ :disabled="props.disabled"
17
+ :error-text="passwordErrorText"
18
+ @set-password-disable="setPasswordDisable"
19
+ @change-password="changePassword"
20
+ @generate-password="onGeneratePassword"
21
+ />
22
+ </template>
23
+
24
+ <script setup lang="ts">
25
+ import type { UI_I_DefaultForm } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/lib/models/interfaces'
26
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
27
+ import { generatePassword } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/lib/utils'
28
+
29
+ const password = defineModel<string>('password', { required: true })
30
+
31
+ const props = defineProps<{
32
+ disabled: boolean
33
+ }>()
34
+ const emits = defineEmits<{
35
+ (event: 'valid', value: boolean): void
36
+ }>()
37
+
38
+ const { $store, $validation }: any = useNuxtApp()
39
+ const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
40
+
41
+ const localization = computed<UI_I_Localization>(() => useLocal())
42
+
43
+ const validation = $validation.call({})
44
+ const defaultForm: UI_I_DefaultForm = {
45
+ password: {
46
+ value: password.value,
47
+ validations: [
48
+ {
49
+ value: 'password',
50
+ errorText: localization.value.common.passwordsMustLeast8CharactersLongContainUpperAndLowerCaseLetterNumberAndSpecialCharacter,
51
+ },
52
+ ],
53
+ },
54
+ }
55
+ const form = ref<UI_I_DefaultForm>(useDeepCopy(defaultForm))
56
+ const setForm = (): void => {
57
+ form.value = useDeepCopy(defaultForm)
58
+ validation.setForm(form)
59
+ }
60
+ setForm()
61
+
62
+ const showValidationErrors = (): void => {
63
+ const valid = validation.touch()
64
+ console.log(valid, 111)
65
+ passwordErrorText.value = !valid.isValid ? valid.errors.password[0] : ''
66
+ emits('valid', valid.isValid)
67
+ }
68
+ const removeValidationErrors = (): void => {
69
+ passwordErrorText.value = ''
70
+ emits('valid', true)
71
+ }
72
+
73
+ const setPasswordDisable = (): void => {
74
+ if (isEnabledPassword.value) {
75
+ return
76
+ }
77
+
78
+ removeValidationErrors()
79
+ setForm()
80
+ password.value = ''
81
+ }
82
+
83
+ const passwordErrorText = ref<string>('')
84
+
85
+ const changePassword = (value: string): void => {
86
+ password.value = value
87
+
88
+ showValidationErrors()
89
+ }
90
+
91
+ const isEnabledPassword = ref<boolean>(!!password.value)
92
+
93
+ const onGeneratePassword = (): void => {
94
+ const generatedPassword = generatePassword()
95
+
96
+ form.value.password.value = generatedPassword
97
+ password.value = generatedPassword
98
+
99
+ showValidationErrors()
100
+ }
101
+ </script>
102
+
103
+ <style scoped></style>
@@ -1,128 +1,128 @@
1
- <template>
2
- <ui-stack-block :has-children="false">
3
- <template #stackBlockKey>
4
- {{ localization.auth.password }}
5
- </template>
6
- <template #stackBlockContent>
7
- <div class="password-content">
8
- <ui-checkbox
9
- id="enable-password"
10
- v-model="isEnabledPassword"
11
- :disabled="props.disabled"
12
- :label-text="localization.common.enable"
13
- test-id="enable-password-input"
14
- size="md"
15
- class="mr-2"
16
- @change="emits('set-password-disable')"
17
- />
18
-
19
- <ui-input-with-tooltip
20
- id="password-input"
21
- v-model="form.password.value"
22
- :class="[{ 'has-error': !!props.errorText }]"
23
- :disabled="!isEnabledPassword || props.disabled"
24
- :error-text="props.errorText"
25
- test-id="password-input"
26
- type="text"
27
- size="sm"
28
- @change="onChangePassword"
29
- >
30
- <template #icon>
31
- <div
32
- :class="[
33
- 'copy-icon pointer',
34
- { disabled: !isEnabledPassword || props.disabled },
35
- ]"
36
- @click="onCopyToClipboard"
37
- >
38
- <ui-icon
39
- name="copy-to-clipboard"
40
- type="input"
41
- width="16"
42
- height="16"
43
- />
44
- </div>
45
- </template>
46
- </ui-input-with-tooltip>
47
-
48
- <ui-button
49
- id="generate-password-button"
50
- :disabled="!isEnabledPassword || props.disabled"
51
- :title="localization.common.generatePassword"
52
- test-id="generate-password-button"
53
- class="generate-password-button"
54
- @click="emits('generate-password')"
55
- >
56
- <ui-icon
57
- name="key"
58
- width="16"
59
- height="16"
60
- class="generate-password-icon"
61
- />
62
- </ui-button>
63
- </div>
64
- </template>
65
- </ui-stack-block>
66
- </template>
67
-
68
- <script setup lang="ts">
69
- import type { UI_I_DefaultForm } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/lib/models/interfaces'
70
- import type { UI_I_Localization } from '~/lib/models/interfaces'
71
-
72
- const isEnabledPassword = defineModel<boolean>('isEnabledPassword', {
73
- required: true,
74
- })
75
- const form = defineModel<UI_I_DefaultForm>('form', { required: true })
76
-
77
- const props = defineProps<{
78
- disabled: boolean
79
- errorText: string
80
- }>()
81
- const emits = defineEmits<{
82
- (event: 'set-password-disable'): void
83
- (event: 'change-password', value: string): void
84
- (event: 'generate-password'): void
85
- }>()
86
-
87
- const localization = computed<UI_I_Localization>(() => useLocal())
88
-
89
- const onChangePassword = (): void => {
90
- emits('change-password', form.value.password.value)
91
- }
92
-
93
- const onCopyToClipboard = (): void => {
94
- navigator.clipboard.writeText(form.value.password.value)
95
- }
96
- </script>
97
-
98
- <style scoped>
99
- .password-content {
100
- display: grid;
101
- grid-template-columns: max-content 144px max-content;
102
- grid-gap: 8px;
103
-
104
- .copy-icon {
105
- color: #9da6ad;
106
-
107
- &.disabled {
108
- color: #bdc3c770;
109
- }
110
- }
111
- .generate-password-button {
112
- padding: 8px;
113
-
114
- &:disabled {
115
- .generate-password-icon {
116
- color: #e9eaec;
117
- }
118
- }
119
- }
120
- }
121
-
122
- :deep(.ui-main.ui-main-sm .ui-main-input) {
123
- height: 32px;
124
- }
125
- :deep(.ui-main.ui-main-sm .ui-slot-icon-content) {
126
- pointer-events: unset;
127
- }
128
- </style>
1
+ <template>
2
+ <ui-stack-block :has-children="false">
3
+ <template #stackBlockKey>
4
+ <span class="mt-2">{{ localization.auth.password }}</span>
5
+ </template>
6
+ <template #stackBlockContent>
7
+ <div class="password-content">
8
+ <ui-checkbox
9
+ id="enable-password"
10
+ v-model="isEnabledPassword"
11
+ :disabled="props.disabled"
12
+ :label-text="localization.common.enable"
13
+ test-id="enable-password-input"
14
+ size="md"
15
+ class="mr-2"
16
+ @change="emits('set-password-disable')"
17
+ />
18
+
19
+ <ui-input-with-tooltip
20
+ id="password-input"
21
+ v-model="form.password.value"
22
+ :class="[{ 'has-error': !!props.errorText }]"
23
+ :disabled="!isEnabledPassword || props.disabled"
24
+ :error-text="props.errorText"
25
+ test-id="password-input"
26
+ type="text"
27
+ size="sm"
28
+ @change="onChangePassword"
29
+ >
30
+ <template #icon>
31
+ <div
32
+ :class="[
33
+ 'copy-icon pointer',
34
+ { disabled: !isEnabledPassword || props.disabled },
35
+ ]"
36
+ @click="onCopyToClipboard"
37
+ >
38
+ <ui-icon
39
+ name="copy-to-clipboard"
40
+ type="input"
41
+ width="16"
42
+ height="16"
43
+ />
44
+ </div>
45
+ </template>
46
+ </ui-input-with-tooltip>
47
+
48
+ <ui-button
49
+ id="generate-password-button"
50
+ :disabled="!isEnabledPassword || props.disabled"
51
+ :title="localization.common.generatePassword"
52
+ test-id="generate-password-button"
53
+ class="generate-password-button"
54
+ @click="emits('generate-password')"
55
+ >
56
+ <ui-icon
57
+ name="key"
58
+ width="16"
59
+ height="16"
60
+ class="generate-password-icon"
61
+ />
62
+ </ui-button>
63
+ </div>
64
+ </template>
65
+ </ui-stack-block>
66
+ </template>
67
+
68
+ <script setup lang="ts">
69
+ import type { UI_I_DefaultForm } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/lib/models/interfaces'
70
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
71
+
72
+ const isEnabledPassword = defineModel<boolean>('isEnabledPassword', {
73
+ required: true,
74
+ })
75
+ const form = defineModel<UI_I_DefaultForm>('form', { required: true })
76
+
77
+ const props = defineProps<{
78
+ disabled: boolean
79
+ errorText: string
80
+ }>()
81
+ const emits = defineEmits<{
82
+ (event: 'set-password-disable'): void
83
+ (event: 'change-password', value: string): void
84
+ (event: 'generate-password'): void
85
+ }>()
86
+
87
+ const localization = computed<UI_I_Localization>(() => useLocal())
88
+
89
+ const onChangePassword = (): void => {
90
+ emits('change-password', form.value.password.value)
91
+ }
92
+
93
+ const onCopyToClipboard = (): void => {
94
+ navigator.clipboard.writeText(form.value.password.value)
95
+ }
96
+ </script>
97
+
98
+ <style scoped>
99
+ .password-content {
100
+ display: grid;
101
+ grid-template-columns: max-content 144px max-content;
102
+ grid-gap: 8px;
103
+
104
+ .copy-icon {
105
+ color: #9da6ad;
106
+
107
+ &.disabled {
108
+ color: #bdc3c770;
109
+ }
110
+ }
111
+ .generate-password-button {
112
+ padding: 8px;
113
+
114
+ &:disabled {
115
+ .generate-password-icon {
116
+ color: #e9eaec;
117
+ }
118
+ }
119
+ }
120
+ }
121
+
122
+ :deep(.ui-main.ui-main-sm .ui-main-input) {
123
+ height: 32px;
124
+ }
125
+ :deep(.ui-main.ui-main-sm .ui-slot-icon-content) {
126
+ pointer-events: unset;
127
+ }
128
+ </style>
@@ -1,28 +1,28 @@
1
- <template>
2
- <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-usb-redirection-new
3
- v-if="isNewView"
4
- v-model:usb-redirection="usbRedirection"
5
- :usb-redirection-options="usbRedirectionOptions"
6
- />
7
- <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-usb-redirection-old
8
- v-else
9
- v-model:usb-redirection="usbRedirection"
10
- :usb-redirection-options="usbRedirectionOptions"
11
- />
12
- </template>
13
-
14
- <script setup lang="ts">
15
- import type { UI_I_OptionItem } from '~/components/atoms/lib/models/interfaces'
16
- import { usbRedirectionOptionsConfig } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/usbRedirection/lib/config/config'
17
-
18
- const usbRedirection = defineModel<number>('usbRedirection', { required: true })
19
-
20
- const { $store }: any = useNuxtApp()
21
- const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
22
-
23
- const usbRedirectionOptions = ref<UI_I_OptionItem[]>(
24
- usbRedirectionOptionsConfig
25
- )
26
- </script>
27
-
28
- <style scoped></style>
1
+ <template>
2
+ <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-usb-redirection-new
3
+ v-if="isNewView"
4
+ v-model:usb-redirection="usbRedirection"
5
+ :usb-redirection-options="usbRedirectionOptions"
6
+ />
7
+ <common-vm-actions-common-customize-hardware-vmoptions-remote-console-options-usb-redirection-old
8
+ v-else
9
+ v-model:usb-redirection="usbRedirection"
10
+ :usb-redirection-options="usbRedirectionOptions"
11
+ />
12
+ </template>
13
+
14
+ <script setup lang="ts">
15
+ import type { UI_I_OptionItem } from '~/components/atoms/lib/models/interfaces'
16
+ import { usbRedirectionOptionsConfig } from '~/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/usbRedirection/lib/config/config'
17
+
18
+ const usbRedirection = defineModel<number>('usbRedirection', { required: true })
19
+
20
+ const { $store }: any = useNuxtApp()
21
+ const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
22
+
23
+ const usbRedirectionOptions = ref<UI_I_OptionItem[]>(
24
+ usbRedirectionOptionsConfig
25
+ )
26
+ </script>
27
+
28
+ <style scoped></style>
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <ui-stack-block :has-children="false">
3
3
  <template #stackBlockKey>
4
- {{ localization.common.usbRedirection }}
4
+ <span class="mt-2">{{ localization.common.usbRedirection }}</span>
5
5
  </template>
6
6
  <template #stackBlockContent>
7
7
  <ui-select