bfg-common 1.5.759 → 1.5.761

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 (34) hide show
  1. package/assets/localization/local_be.json +13 -3
  2. package/assets/localization/local_en.json +13 -3
  3. package/assets/localization/local_hy.json +13 -3
  4. package/assets/localization/local_kk.json +13 -3
  5. package/assets/localization/local_ru.json +13 -3
  6. package/assets/localization/local_zh.json +14 -4
  7. package/components/common/layout/theHeader/New.vue +2 -0
  8. package/components/common/layout/theHeader/Old.vue +2 -0
  9. package/components/common/layout/theHeader/TheHeader.vue +2 -0
  10. package/components/common/layout/theHeader/modals/reconnect/New.vue +1 -1
  11. package/components/common/layout/theHeader/modals/reconnect/Reconnect.vue +3 -1
  12. package/components/common/layout/theHeader/userMenu/UserMenu.vue +2 -0
  13. package/components/common/layout/theHeader/userMenu/modals/preferences/New.vue +2 -0
  14. package/components/common/layout/theHeader/userMenu/modals/preferences/Old.vue +2 -0
  15. package/components/common/layout/theHeader/userMenu/modals/preferences/Preferences.vue +2 -0
  16. package/components/common/layout/theHeader/userMenu/modals/preferences/view/New.vue +17 -0
  17. package/components/common/layout/theHeader/userMenu/modals/preferences/view/Old.vue +19 -0
  18. package/components/common/layout/theHeader/userMenu/modals/preferences/view/View.vue +3 -0
  19. package/components/common/pages/backups/backupsNew/BackupsNew.vue +107 -19
  20. package/components/common/pages/backups/backupsNew/Skeleton.vue +136 -0
  21. package/components/common/pages/backups/backupsNew/contextMenuView/ContextMenuView.vue +16 -10
  22. package/components/common/pages/backups/modals/createBackup/configuration/backupWindow/BackupWindow.vue +29 -29
  23. package/components/common/pages/backups/modals/createBackup/configuration/maxBandwidth/MaxBandwidth.vue +69 -69
  24. package/components/common/pages/backups/modals/createBackup/configuration/maxBandwidth/lib/config/options.ts +6 -6
  25. package/components/common/pages/backups/modals/createBackup/configuration/strategy/Strategy.vue +38 -38
  26. package/components/common/pages/backups/modals/createBackup/datastores/tableView/new/lib/config/table.ts +1 -1
  27. package/components/common/pages/backups/modals/createBackup/lib/config/strategyOptions.ts +8 -11
  28. package/components/common/pages/backups/modals/createBackup/lib/models/interfaces.ts +8 -8
  29. package/components/common/vm/snapshots/new/New.vue +11 -12
  30. package/components/common/vm/snapshots/new/Skeleton.vue +26 -2
  31. package/components/common/wizards/network/add/Add.vue +9 -6
  32. package/components/common/wizards/network/add/lib/config/initialData.ts +2 -1
  33. package/lib/models/interfaces.ts +1 -0
  34. package/package.json +1 -1
@@ -1,38 +1,38 @@
1
- <template>
2
- <atoms-stack-block
3
- :has-children="false"
4
- test-id="backup-strategy-stack-block"
5
- >
6
- <template #stackBlockKey>
7
- <span>{{ localization.common.strategy }}</span>
8
- </template>
9
- <template #stackBlockContent>
10
- <common-select-input
11
- v-model="model.strategy"
12
- :data="strategyOptions"
13
- test-id="backup-strategy"
14
- />
15
- </template>
16
- </atoms-stack-block>
17
- </template>
18
-
19
- <script lang="ts" setup>
20
- import type { UI_I_Localization } from '~/lib/models/interfaces'
21
- import type { UI_I_CreateBackupForm } from '~/components/common/pages/backups/modals/lib/models/interfaces'
22
- import type { UI_I_SelectInputItem } from '~/components/common/select/input/lib/models/interfaces'
23
- import { strategyOptionsFunc } from '~/components/common/pages/backups/modals/createBackup/lib/config/strategyOptions'
24
-
25
- const model = defineModel<UI_I_CreateBackupForm>({ required: true })
26
-
27
- const localization = computed<UI_I_Localization>(() => useLocal())
28
-
29
- const strategyOptions = ref<UI_I_SelectInputItem[]>(
30
- strategyOptionsFunc(localization.value)
31
- )
32
- </script>
33
-
34
- <style lang="scss" scoped>
35
- #backup-transaction-logs {
36
- margin: 4px 4px 0 0;
37
- }
38
- </style>
1
+ <template>
2
+ <atoms-stack-block
3
+ :has-children="false"
4
+ test-id="backup-strategy-stack-block"
5
+ >
6
+ <template #stackBlockKey>
7
+ <span>{{ localization.common.strategy }}</span>
8
+ </template>
9
+ <template #stackBlockContent>
10
+ <common-select-input
11
+ v-model="model.strategy"
12
+ :data="strategyOptions"
13
+ test-id="backup-strategy"
14
+ />
15
+ </template>
16
+ </atoms-stack-block>
17
+ </template>
18
+
19
+ <script lang="ts" setup>
20
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
21
+ import type { UI_I_CreateBackupForm } from '~/components/common/pages/backups/modals/lib/models/interfaces'
22
+ import type { UI_I_SelectInputItem } from '~/components/common/select/input/lib/models/interfaces'
23
+ import { strategyOptionsFunc } from '~/components/common/pages/backups/modals/createBackup/lib/config/strategyOptions'
24
+
25
+ const model = defineModel<UI_I_CreateBackupForm>({ required: true })
26
+
27
+ const localization = computed<UI_I_Localization>(() => useLocal())
28
+
29
+ const strategyOptions = ref<UI_I_SelectInputItem[]>(
30
+ strategyOptionsFunc(localization.value)
31
+ )
32
+ </script>
33
+
34
+ <style lang="scss" scoped>
35
+ #backup-transaction-logs {
36
+ margin: 4px 4px 0 0;
37
+ }
38
+ </style>
@@ -7,7 +7,7 @@ import type { UI_I_Localization } from '~/lib/models/interfaces'
7
7
  import type {
8
8
  UI_I_BackupDatastore,
9
9
  } from '~/components/common/pages/backups/modals/lib/models/interfaces'
10
- import {backupStorageIconByState, datastoreLocalizationByState} from '~/components/common/lib/config/states'
10
+ import { backupStorageIconByState, datastoreLocalizationByState } from '~/components/common/lib/config/states'
11
11
  import type {
12
12
  I_BackupDatastoreChipStatus
13
13
  } from "~/components/common/pages/backups/modals/createBackup/datastores/tableView/new/lib/models/interfaces";
@@ -2,24 +2,21 @@ import type { UI_I_Localization } from '~/lib/models/interfaces'
2
2
  import type { UI_I_SelectInputItem } from '~/components/common/select/input/lib/models/interfaces'
3
3
 
4
4
  export const strategyOptionsFunc = (
5
- localization: UI_I_Localization
5
+ localization: UI_I_Localization
6
6
  ): UI_I_SelectInputItem[] => {
7
7
  const { $text } = useNuxtApp()
8
8
  const isLangEn = useLocalStorage('lang') === 'en_US'
9
9
 
10
- let labels = [
10
+ const labels = [
11
11
  { label: localization.common.fullBackup, value: 0 },
12
12
  { label: localization.common.incrementalBackup, value: 1 },
13
13
  { label: localization.common.differentialBackup, value: 2 },
14
14
  ]
15
15
 
16
- if(isLangEn) {
17
- labels = labels.map((item) => ({
18
- ...item,
19
- label: $text.toCapitalizeEveryWord(item.label)
20
- }))
21
- }
22
-
23
- return labels
16
+ return isLangEn
17
+ ? labels.map((item) => ({
18
+ ...item,
19
+ label: $text.toCapitalizeEveryWord(item.label),
20
+ }))
21
+ : labels
24
22
  }
25
-
@@ -1,8 +1,8 @@
1
- export interface UI_I_DynamicSteps {
2
- general: number
3
- disks: number
4
- datastores: number
5
- configuration: number
6
- readyComplete: number
7
- schedulingOptions: number
8
- }
1
+ export interface UI_I_DynamicSteps {
2
+ general: number
3
+ disks: number
4
+ datastores: number
5
+ configuration: number
6
+ readyComplete: number
7
+ schedulingOptions: number
8
+ }
@@ -227,6 +227,7 @@
227
227
  </template>
228
228
 
229
229
  <script setup lang="ts">
230
+ import { useTemplateRef } from 'vue'
230
231
  import { useElementSize } from '@vueuse/core'
231
232
  import type { UI_I_InfoBlock } from '~/node_modules/bfg-uikit/components/ui/infoBlock/models/interfaces'
232
233
  import type { UI_I_Localization } from '~/lib/models/interfaces'
@@ -268,19 +269,14 @@ const onSelectContextMenuItem = (actionType: UI_T_SnapshotActionType): void => {
268
269
  emits('show-modal', actionType)
269
270
  }
270
271
 
271
- const detailsScrollBlock = ref<HTMLElement | null>(null)
272
- const { height } = useElementSize(detailsScrollBlock)
273
- const hasScroll = ref<boolean>(false)
274
- const checkScroll = (): void => {
275
- const element = detailsScrollBlock.value
276
- if (element) {
277
- hasScroll.value = element.scrollHeight > element.clientHeight
278
- }
279
- }
272
+ const detailsElement = useTemplateRef<HTMLDivElement>('detailsScrollBlock')
273
+ const { height } = useElementSize(detailsElement)
280
274
 
281
- watch(height, () => {
282
- checkScroll()
283
- })
275
+ const hasScroll = computed<boolean>(
276
+ () =>
277
+ height.value &&
278
+ detailsElement.value?.scrollHeight > detailsElement.value?.clientHeight
279
+ )
284
280
  </script>
285
281
 
286
282
  <style>
@@ -433,6 +429,9 @@ watch(height, () => {
433
429
  line-height: 18px;
434
430
  text-align: right;
435
431
  }
432
+ :deep(.ui-main-info-block-item) {
433
+ grid-column-gap: 10px;
434
+ }
436
435
  :deep(.ui-main-info-block-item-right) {
437
436
  white-space: unset !important;
438
437
  max-width: 50%;
@@ -19,7 +19,7 @@
19
19
  <ui-skeleton-item width="96" height="20" class="ml-auto" />
20
20
  </div>
21
21
  <div class="right-content grid p-4">
22
- <div class="flex justify-between gap-4 flex-wrap top-container">
22
+ <div class="flex justify-between gap-4 pr-4 flex-wrap top-container">
23
23
  <ui-skeleton-item width="80" height="20" />
24
24
  <div class="actions-block flex">
25
25
  <ui-skeleton-item width="20" height="20" />
@@ -29,7 +29,13 @@
29
29
  <ui-skeleton-item width="20" height="20" />
30
30
  </div>
31
31
  </div>
32
- <div class="details-block flex flex-col my-6">
32
+ <div
33
+ ref="detailsScrollBlock"
34
+ :class="[
35
+ 'details-block flex flex-col my-6',
36
+ { 'has-scroll': hasScroll },
37
+ ]"
38
+ >
33
39
  <div
34
40
  v-for="index in detailsItemsCount"
35
41
  :key="index"
@@ -45,7 +51,19 @@
45
51
  </template>
46
52
 
47
53
  <script setup lang="ts">
54
+ import { useTemplateRef } from 'vue'
55
+ import { useElementSize } from '@vueuse/core'
56
+
48
57
  const detailsItemsCount = ref<number>(6)
58
+
59
+ const detailsElement = useTemplateRef<HTMLDivElement>('detailsScrollBlock')
60
+ const { height } = useElementSize(detailsElement)
61
+
62
+ const hasScroll = computed<boolean>(
63
+ () =>
64
+ height.value &&
65
+ detailsElement.value?.scrollHeight > detailsElement.value?.clientHeight
66
+ )
49
67
  </script>
50
68
 
51
69
  <style>
@@ -84,6 +102,8 @@ const detailsItemsCount = ref<number>(6)
84
102
  }
85
103
  }
86
104
  .right-content {
105
+ padding-right: 0;
106
+
87
107
  .top-container {
88
108
  .actions-block {
89
109
  grid-column-gap: 10px;
@@ -98,6 +118,10 @@ const detailsItemsCount = ref<number>(6)
98
118
  grid-row-gap: 10px;
99
119
  overflow: auto;
100
120
 
121
+ &:not(.has-scroll) {
122
+ padding-right: 16px;
123
+ }
124
+
101
125
  .details-block-item {
102
126
  background-color: var(--snapshots-right-skeleton-item-bg-color);
103
127
  border-radius: 6px;
@@ -251,10 +251,12 @@ const globalPermissions = computed<any>(
251
251
 
252
252
  // Step's content data (connectionType)
253
253
  const connectionType = ref<string>(
254
- !globalPermissions.value['Networks.CreateSysx'] &&
255
- !globalPermissions.value['Networks.CreatePortGroup']
254
+ globalPermissions.value === undefined
255
+ ? '0'
256
+ : !globalPermissions.value?.['Networks.CreateSysx'] &&
257
+ !globalPermissions.value?.['Networks.CreatePortGroup']
256
258
  ? '2'
257
- : !globalPermissions.value['Networks.CreateSysx']
259
+ : !globalPermissions.value?.['Networks.CreateSysx']
258
260
  ? '1'
259
261
  : '0'
260
262
  )
@@ -291,7 +293,7 @@ const onChangeAdapterStatus = (adapterStatusNew: UI_I_AdapterStatus): void => {
291
293
  // Step's content data and changers (targetDevice)
292
294
  const targetDevice = ref<UI_I_TargetDevice>(
293
295
  useDeepCopy(
294
- targetDeviceInitialFunc(globalPermissions.value['Networks.UpdateSwitch'])
296
+ targetDeviceInitialFunc(globalPermissions.value?.['Networks.UpdateSwitch'])
295
297
  )
296
298
  )
297
299
  const mtuFromSwitch = ref<number>(1500)
@@ -385,7 +387,8 @@ watch(
385
387
  : (targetDevice.value.selected = '0')
386
388
  newCT === '1' && (targetDevice.value.selected = '1')
387
389
  newCT === '2' &&
388
- (globalPermissions.value['Networks.UpdateSwitch']
390
+ (globalPermissions.value === undefined ||
391
+ globalPermissions.value?.['Networks.UpdateSwitch']
389
392
  ? (targetDevice.value.selected = '2')
390
393
  : (targetDevice.value.selected = '3'))
391
394
  }
@@ -515,7 +518,7 @@ const reset = (): void => {
515
518
  wizard.reset()
516
519
  connectionTypeLocal.value = '0'
517
520
  targetDevice.value = useDeepCopy(
518
- targetDeviceInitialFunc(globalPermissions.value['Networks.UpdateSwitch'])
521
+ targetDeviceInitialFunc(globalPermissions.value?.['Networks.UpdateSwitch'])
519
522
  )
520
523
  connectionSettings.value = useDeepCopy(connectionSettingsInitial)
521
524
  portProperties.value = useDeepCopy(portPropertiesInitial)
@@ -25,7 +25,8 @@ export const servicesInitial: UI_I_Services = {
25
25
  export const targetDeviceInitialFunc = (
26
26
  updateSwitchPermission: boolean
27
27
  ): UI_I_TargetDevice => ({
28
- selected: updateSwitchPermission ? '1' : '3',
28
+ selected:
29
+ updateSwitchPermission === undefined || updateSwitchPermission ? '1' : '3',
29
30
  network: '',
30
31
  switch: '',
31
32
  standardSwitch: '',
@@ -61,6 +61,7 @@ export interface UI_I_Localization {
61
61
  files: UI_I_ArbitraryObject<string>
62
62
  myPreferences: UI_I_ArbitraryObject<string>
63
63
  cacheConfiguration: UI_I_ArbitraryObject<string>
64
+ configureSecurityProfile: UI_I_ArbitraryObject<string>
64
65
  }
65
66
  export interface UI_I_SendTaskParams {
66
67
  method: string
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "bfg-common",
3
3
  "private": false,
4
- "version": "1.5.759",
4
+ "version": "1.5.761",
5
5
  "scripts": {
6
6
  "build": "nuxt build",
7
7
  "dev": "nuxt dev --port=3002",