@dev.smartpricing/message-composer-layer 4.2.14 → 4.3.1

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.
@@ -2,11 +2,28 @@
2
2
  import ColorInput from '~/components/Common/ColorInput.vue'
3
3
  import FontFamilySelect from '~/components/Common/FontFamilySelect.vue'
4
4
  import type { SafeFonts } from '@dev.smartpricing/message-composer-utils/types'
5
+ import { DEFAULT_EMAIL_GLOBAL_SETTINGS } from '@dev.smartpricing/message-composer-utils/types'
5
6
 
6
7
  const emailEditorStore = useEmailEditorStore()
7
8
 
8
9
  const { brand, globalSettings, brandColors } = storeToRefs(emailEditorStore)
9
10
 
11
+ // SSlider v-model is a plain number; the stored settings keep spacing optional.
12
+ const verticalSpacing = computed({
13
+ get: () => globalSettings.value.verticalSpacing ?? DEFAULT_EMAIL_GLOBAL_SETTINGS.verticalSpacing,
14
+ set: (value: number) => {
15
+ globalSettings.value.verticalSpacing = value
16
+ },
17
+ })
18
+
19
+ const horizontalSpacing = computed({
20
+ get: () =>
21
+ globalSettings.value.horizontalSpacing ?? DEFAULT_EMAIL_GLOBAL_SETTINGS.horizontalSpacing,
22
+ set: (value: number) => {
23
+ globalSettings.value.horizontalSpacing = value
24
+ },
25
+ })
26
+
10
27
  defineOptions({
11
28
  name: 'EmailEditorGeneralStyleSettings',
12
29
  })
@@ -83,7 +100,7 @@ defineOptions({
83
100
  :data-testid="generalStyleSettingsTestIds.verticalSpacingField"
84
101
  >
85
102
  <SSlider
86
- v-model="globalSettings.verticalSpacing"
103
+ v-model="verticalSpacing"
87
104
  :min="0"
88
105
  :max="50"
89
106
  :data-testid="generalStyleSettingsTestIds.verticalSpacingSlider"
@@ -96,7 +113,7 @@ defineOptions({
96
113
  :data-testid="generalStyleSettingsTestIds.horizontalSpacingField"
97
114
  >
98
115
  <SSlider
99
- v-model="globalSettings.horizontalSpacing"
116
+ v-model="horizontalSpacing"
100
117
  :min="0"
101
118
  :max="50"
102
119
  :data-testid="generalStyleSettingsTestIds.horizontalSpacingSlider"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dev.smartpricing/message-composer-layer",
3
- "version": "4.2.14",
3
+ "version": "4.3.1",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "main": "./nuxt.config.ts",
@@ -12,7 +12,7 @@
12
12
  "app.config.ts"
13
13
  ],
14
14
  "dependencies": {
15
- "@dev.smartpricing/platform-layer": "^0.0.9",
15
+ "@dev.smartpricing/platform-layer": "^0.0.23",
16
16
  "@formkit/drag-and-drop": "^0.5.3",
17
17
  "@pinia/colada": "^1.3.0",
18
18
  "@tiptap/extension-character-count": "^3.23.4",
@@ -36,14 +36,14 @@
36
36
  "vue-router": "^5.0.7",
37
37
  "vue3-emoji-picker": "^1.1.8",
38
38
  "zod": "^4.4.3",
39
- "@dev.smartpricing/message-composer-utils": "4.2.14"
39
+ "@dev.smartpricing/message-composer-utils": "4.3.1"
40
40
  },
41
41
  "devDependencies": {
42
42
  "@nuxt/eslint": "^1.15.2",
43
43
  "@nuxt/test-utils": "^4.0.3",
44
44
  "@playwright/test": "^1.60.0",
45
45
  "dotenv": "^17.4.2",
46
- "nuxt-ui-layer": "git+ssh://git@github.com:smartpricing/smartness-nuxt-ui#v1.7.2",
46
+ "nuxt-ui-layer": "git+ssh://git@github.com:smartpricing/smartness-nuxt-ui#v1.14.4",
47
47
  "tsx": "^4.19.4",
48
48
  "vue-tsc": "^3.2.9"
49
49
  },