admins-components 9.0.23 → 9.0.25
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/README.md +15 -65
- package/dist/admins-components15.js +17 -23
- package/dist/admins-components15.js.map +1 -1
- package/dist/admins-components153.js.map +1 -1
- package/dist/admins-components157.js +3 -3
- package/dist/admins-components157.js.map +1 -1
- package/dist/admins-components158.js.map +1 -1
- package/dist/admins-components16.js.map +1 -1
- package/dist/admins-components160.js.map +1 -1
- package/dist/admins-components162.js.map +1 -1
- package/dist/admins-components163.js.map +1 -1
- package/dist/admins-components164.js.map +1 -1
- package/dist/admins-components166.js.map +1 -1
- package/dist/admins-components169.js +2 -2
- package/dist/admins-components169.js.map +1 -1
- package/dist/admins-components20.js +87 -87
- package/dist/admins-components20.js.map +1 -1
- package/dist/admins-components22.js.map +1 -1
- package/dist/admins-components69.js +1 -0
- package/dist/admins-components69.js.map +1 -1
- package/dist/admins-components71.js.map +1 -1
- package/dist/admins-components78.js +93 -89
- package/dist/admins-components78.js.map +1 -1
- package/dist/admins-components80.js.map +1 -1
- package/dist/admins-components87.js +26 -35
- package/dist/admins-components87.js.map +1 -1
- package/dist/admins-components89.js.map +1 -1
- package/dist/main.css +1 -0
- package/dist/main.css.map +1 -0
- package/dist/src/styles/components/data-table/data-paginator.scss_vue_type_style_index_0_src_true_lang.css +1 -1
- package/dist/src/vueformelements/ArticlePickerElement.vue_vue_type_style_index_0_scoped_43c54caa_lang.css +1 -0
- package/dist/src/vueformelements/PartnerPickerElement.vue_vue_type_style_index_0_scoped_09bea4ae_lang.css +1 -0
- package/package.json +3 -3
- package/dist/base.css +0 -1
- package/dist/base.css.map +0 -1
- package/dist/src/services/articleEditorService_short_try.d.ts +0 -43
- package/dist/src/vueformelements/ArticlePickerElement.vue_vue_type_style_index_0_scoped_035d2808_lang.css +0 -1
- package/dist/src/vueformelements/PartnerPickerElement.vue_vue_type_style_index_0_scoped_64cb4d6e_lang.css +0 -1
package/README.md
CHANGED
|
@@ -1,94 +1,44 @@
|
|
|
1
1
|
# admins-components
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
### Docs
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
API dokumentáció: ```docs/index.html```
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
## Recommended Browser Setup
|
|
10
|
-
|
|
11
|
-
- Chromium-based browsers (Chrome, Edge, Brave, etc.):
|
|
12
|
-
- [Vue.js devtools](https://chromewebstore.google.com/detail/vuejs-devtools/nhdogjmejiglipccpnnnanhbledajbpd)
|
|
13
|
-
- [Turn on Custom Object Formatter in Chrome DevTools](http://bit.ly/object-formatters)
|
|
14
|
-
- Firefox:
|
|
15
|
-
- [Vue.js devtools](https://addons.mozilla.org/en-US/firefox/addon/vue-js-devtools/)
|
|
16
|
-
- [Turn on Custom Object Formatter in Firefox DevTools](https://fxdx.dev/firefox-devtools-custom-object-formatters/)
|
|
17
|
-
|
|
18
|
-
## Type Support for `.vue` Imports in TS
|
|
19
|
-
|
|
20
|
-
TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) to make the TypeScript language service aware of `.vue` types.
|
|
21
|
-
|
|
22
|
-
## Customize configuration
|
|
23
|
-
|
|
24
|
-
See [Vite Configuration Reference](https://vite.dev/config/).
|
|
25
|
-
|
|
26
|
-
## Project Setup
|
|
7
|
+
## Setup
|
|
27
8
|
|
|
28
9
|
```sh
|
|
29
10
|
npm install
|
|
30
11
|
```
|
|
31
12
|
|
|
32
|
-
###
|
|
33
|
-
|
|
13
|
+
### Futtatás local
|
|
34
14
|
```sh
|
|
35
15
|
npm run dev
|
|
36
16
|
```
|
|
37
17
|
|
|
38
|
-
###
|
|
18
|
+
### Build project as component lib
|
|
39
19
|
|
|
40
20
|
```sh
|
|
41
21
|
npm run build
|
|
42
22
|
```
|
|
43
23
|
|
|
44
|
-
###
|
|
45
|
-
|
|
46
|
-
```sh
|
|
47
|
-
npm run test:unit
|
|
48
|
-
```
|
|
49
|
-
|
|
50
|
-
### Lint with [ESLint](https://eslint.org/)
|
|
51
|
-
|
|
52
|
-
```sh
|
|
53
|
-
npm run lint
|
|
54
|
-
```
|
|
55
|
-
|
|
56
|
-
## Library Build & Consumer Usage
|
|
57
|
-
|
|
58
|
-
### Building the library
|
|
59
|
-
|
|
60
|
-
```sh
|
|
61
|
-
npm run build:lib
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
This produces:
|
|
65
|
-
- `dist/admins-components.js` — ES module entry (re-exports all components)
|
|
66
|
-
- `dist/base.css` — tokens (CSS variables) + shared controls (consumer imports once)
|
|
67
|
-
- `dist/styles/*.css` — per-component CSS (auto-imported by each component's JS chunk)
|
|
68
|
-
|
|
69
|
-
### Style architecture
|
|
70
|
-
|
|
71
|
-
- **`base.css`** — CSS custom properties and shared form primitives (`c-input`, `c-input-row`, `c-icon-btn`, etc.). Consumer imports this once.
|
|
72
|
-
- **Per-component CSS** — each component's JS chunk includes an `import './styles/....css'` statement. When the consumer's bundler imports a component, its CSS comes along automatically.
|
|
73
|
-
|
|
74
|
-
### Consumer usage
|
|
24
|
+
### Használat
|
|
75
25
|
|
|
76
26
|
```ts
|
|
77
27
|
// main.ts
|
|
78
|
-
import 'admins-components/
|
|
28
|
+
import 'admins-components/main.css' // ebben találhatók az általános, nem közvetlen komponenshez tartozó stílusok
|
|
79
29
|
import { Calendar } from 'admins-components' // component CSS auto-included
|
|
80
30
|
```
|
|
81
31
|
|
|
82
|
-
###
|
|
32
|
+
### Homokozó
|
|
33
|
+
|
|
34
|
+
A `consumer-playground` projektben lehet tesztelni.
|
|
83
35
|
|
|
84
|
-
|
|
36
|
+
### Publish
|
|
85
37
|
|
|
86
38
|
```sh
|
|
87
|
-
|
|
88
|
-
cd admins-components
|
|
89
|
-
npm run build:lib
|
|
39
|
+
npm run build
|
|
90
40
|
|
|
91
|
-
|
|
92
|
-
cd consumer-playground
|
|
93
|
-
npm run dev
|
|
41
|
+
npm publish --access public
|
|
94
42
|
```
|
|
43
|
+
|
|
44
|
+
Publishhoz kell ```npm adduser```
|
|
@@ -1,11 +1,6 @@
|
|
|
1
|
-
import { createCommentVNode as e, createElementBlock as t, createElementVNode as n, defineComponent as r, normalizeClass as i, openBlock as a, toDisplayString as o, useId as s
|
|
1
|
+
import { createCommentVNode as e, createElementBlock as t, createElementVNode as n, defineComponent as r, normalizeClass as i, openBlock as a, toDisplayString as o, useId as s } from "vue";
|
|
2
2
|
//#region src/components/Checkbox.vue?vue&type=script&setup=true&lang.ts
|
|
3
|
-
var
|
|
4
|
-
"aria-checked",
|
|
5
|
-
"aria-disabled",
|
|
6
|
-
"tabindex",
|
|
7
|
-
"onKeydown"
|
|
8
|
-
], f = /* @__PURE__ */ r({
|
|
3
|
+
var c = { class: "c-checkbox-wrapper" }, l = ["checked", "disabled"], u = /* @__PURE__ */ r({
|
|
9
4
|
__name: "Checkbox",
|
|
10
5
|
props: {
|
|
11
6
|
modelValue: {
|
|
@@ -20,30 +15,29 @@ var u = { class: "c-checkbox-wrapper" }, d = [
|
|
|
20
15
|
labelAlignmentFix: { type: Boolean }
|
|
21
16
|
},
|
|
22
17
|
emits: ["update:modelValue"],
|
|
23
|
-
setup(r, { emit:
|
|
24
|
-
let
|
|
25
|
-
function
|
|
26
|
-
|
|
18
|
+
setup(r, { emit: u }) {
|
|
19
|
+
let d = r, f = u, p = `c-checkbox-${s()}`;
|
|
20
|
+
function m(e) {
|
|
21
|
+
if (d.disabled) return;
|
|
22
|
+
let t = e.target;
|
|
23
|
+
f("update:modelValue", t.checked || void 0);
|
|
27
24
|
}
|
|
28
|
-
return (s,
|
|
25
|
+
return (s, u) => (a(), t("div", c, [n("input", {
|
|
26
|
+
type: "checkbox",
|
|
29
27
|
class: i(["c-checkbox", {
|
|
30
28
|
"c-checkbox--checked": !!r.modelValue,
|
|
31
29
|
"c-checkbox--disabled": r.disabled
|
|
32
30
|
}]),
|
|
33
|
-
id:
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
onClick: g,
|
|
39
|
-
onKeydown: [c(l(g, ["prevent"]), ["enter"]), c(l(g, ["prevent"]), ["space"])]
|
|
40
|
-
}, null, 42, d), r.label ? (a(), t("label", {
|
|
31
|
+
id: p,
|
|
32
|
+
checked: !!r.modelValue,
|
|
33
|
+
disabled: r.disabled,
|
|
34
|
+
onChange: m
|
|
35
|
+
}, null, 42, l), r.label ? (a(), t("label", {
|
|
41
36
|
key: 0,
|
|
42
37
|
class: "c-label pointer",
|
|
43
|
-
|
|
44
|
-
for: h
|
|
38
|
+
for: p
|
|
45
39
|
}, o(r.label), 1)) : e("", !0)]));
|
|
46
40
|
}
|
|
47
41
|
});
|
|
48
42
|
//#endregion
|
|
49
|
-
export {
|
|
43
|
+
export { u as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components15.js","names":[],"sources":["../src/components/Checkbox.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { useId } from 'vue'\n\nconst props = withDefaults(\n defineProps<{\n modelValue?: boolean\n label?: string\n disabled?: boolean\n labelAlignmentFix?: boolean\n }>(),\n {\n modelValue: undefined,\n label: undefined,\n disabled: false,\n },\n)\n\nconst emit = defineEmits<{\n 'update:modelValue': [value: boolean | undefined]\n}>()\n\nconst inputId = `c-checkbox-${useId()}`\n\nfunction
|
|
1
|
+
{"version":3,"file":"admins-components15.js","names":[],"sources":["../src/components/Checkbox.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { useId } from 'vue'\n\nconst props = withDefaults(\n defineProps<{\n modelValue?: boolean\n label?: string\n disabled?: boolean\n labelAlignmentFix?: boolean\n }>(),\n {\n modelValue: undefined,\n label: undefined,\n disabled: false,\n },\n)\n\nconst emit = defineEmits<{\n 'update:modelValue': [value: boolean | undefined]\n}>()\n\nconst inputId = `c-checkbox-${useId()}`\n\nfunction onChange(event: Event) {\n if (props.disabled) return\n\n const target = event.target as HTMLInputElement\n emit('update:modelValue', target.checked || undefined)\n}\n</script>\n\n<template>\n <div class=\"c-checkbox-wrapper\">\n <input\n type=\"checkbox\"\n class=\"c-checkbox\"\n :class=\"{\n 'c-checkbox--checked': !!modelValue,\n 'c-checkbox--disabled': disabled,\n }\"\n :id=\"inputId\"\n :checked=\"!!modelValue\"\n :disabled=\"disabled\"\n @change=\"onChange\"\n />\n<!-- :class=\"{ 'align-center-fix': labelAlignmentFix }\" -->\n <label\n v-if=\"label\"\n class=\"c-label pointer\"\n :for=\"inputId\"\n >\n {{ label }}\n </label>\n </div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;EAGA,IAAM,IAAQ,GAcR,IAAO,GAIP,IAAU,cAAc,EAAM;EAEpC,SAAS,EAAS,GAAc;GAC9B,IAAI,EAAM,UAAU;GAEpB,IAAM,IAAS,EAAM;GACrB,EAAK,qBAAqB,EAAO,WAAW,KAAA,CAAS;EACvD;yBAIE,EAqBM,OArBN,GAqBM,CApBJ,EAWE,SAAA;GAVA,MAAK;GACL,OAAK,EAAA,CAAC,cAAY;6BACyB,EAAA;4BAA4C,EAAA;;GAItF,IAAI;GACJ,SAAO,CAAA,CAAI,EAAA;GACX,UAAU,EAAA;GACF;mBAIH,EAAA,SAAA,EAAA,GADR,EAMQ,SAAA;;GAJN,OAAM;GACL,KAAK;OAEH,EAAA,KAAK,GAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components153.js","names":[],"sources":["../src/vueformelements/ArticleOfferElement.vue"],"sourcesContent":["<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, onMounted, onUnmounted, nextTick } from 'vue'\nimport { aoeConfig } from '@/vueformelements/config/ArticleOfferElementConfig'\nimport Button from '@/components/Button.vue'\n\nexport default defineElement({\n components: { Button },\n name: 'ArticleOfferElement',\n\n setup(props, context) {\n const articleEditorUrl = aoeConfig.articleEditorUrl\n const environment = aoeConfig.environment\n const searchImageWidgetUrl = aoeConfig.searchImageWidgetUrl\n const imageBaseUrl = aoeConfig.imageBaseUrl\n const imageViewId = aoeConfig.imageViewId\n const onFetchMetaTags = aoeConfig.onFetchMetaTags\n\n const imageCausationId = ref(new Date().getTime().toString() + 'image')\n\n const EMPTYGUID = '00000000-0000-0000-0000-000000000000'\n\n const { value } = context.element\n\n const gotMetagTags = (url, imageUrl, title, lead) => {\n if (url === value.value['url']) {\n value.value.image = imageUrl\n value.value.title = title\n value.value.lead = lead\n }\n }\n\n aoeConfig.gotMetagTags = gotMetagTags\n const fetchMetaTags = () => {\n if (!value.value['url']) return\n aoeConfig.onFetchMetaTags(value.value['url'])\n }\n\n const selectImage = (event) => {\n // we need this guy, otherwise the form will be saved\n event.preventDefault()\n nextTick(() => {\n document.getElementById(imageCausationId.value).showModal()\n })\n }\n\n const resetImage = (event) => {\n event.preventDefault()\n value.value.imageId = EMPTYGUID\n value.value.image = ''\n }\n\n const addScript = (url) => {\n if (!document.querySelector(`script[src=\"${url}\"]`)) {\n const script = document.createElement('script')\n script.type = 'text/javascript'\n script.src = url\n document.head.appendChild(script)\n }\n }\n\n const ImageSelectedHandler = (e) => {\n if (e.detail.causationid == imageCausationId.value) {\n document.getElementById(imageCausationId.value).close()\n const image = e.detail.image\n value.value.image = image.url\n }\n }\n\n onUnmounted(() => {\n window.removeEventListener('image-selected', ImageSelectedHandler, false)\n })\n\n onMounted(() => {\n window.addEventListener('image-selected', ImageSelectedHandler)\n })\n\n addScript(searchImageWidgetUrl)\n\n return {\n articleEditorUrl,\n environment,\n imageViewId,\n imageBaseUrl,\n imageCausationId: imageCausationId,\n searchImageWidgetUrl,\n selectImage,\n resetImage,\n addScript,\n value,\n fetchMetaTags,\n onFetchMetaTags,\n gotMetagTags,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template v-if=\"value\" #element>\n <div class=\"ac-component\">\n <label for=\"articleUrl\" class=\"c-label\">Cikk url</label>\n <div class=\"c-input-row\">\n <input\n type=\"text\"\n id=\"articleUrl\"\n class=\"c-input\"\n placeholder=\"Cikk url\"\n :value=\"value.url\"\n @input=\"\n (event) => {\n value.url = event.target.value\n }\n \"\n @blur=\"fetchMetaTags\"\n />\n </div>\n </div>\n <div>\n <label for=\"articleTitle\" class=\"c-label\">Címe</label>\n <div class=\"c-input-row\">\n <textarea\n id=\"articleTitle\"\n class=\"c-input\"\n placeholder=\"Címe\"\n :value=\"value.title\"\n @input=\"value.title = $event.target.value\"\n ></textarea>\n </div>\n </div>\n <div>\n <label for=\"articleLead\" class=\"c-label\">Lead</label>\n <div class=\"c-input-row\">\n <textarea\n id=\"articleLead\"\n class=\"c-input\"\n placeholder=\"Lead\"\n :value=\"value.lead\"\n @input=\"value.lead = $event.target.value\"\n ></textarea>\n </div>\n </div>\n <div>\n <label class=\"c-label\" style=\"display: block\">Kép</label>\n <img\n alt=\"\"\n :src=\"value.image\"\n @input=\"value.image = $event.target.value\"\n style=\"height: 200px\"\n />\n </div>\n <div v-if=\"value.imageId === '00000000-0000-0000-0000-000000000000'\">\n Nincs kép kiválasztva!\n </div>\n <div class=\"flex-center mt-2 w-100\" role=\"group\" aria-label=\"Képválasztó gombok\">\n <Button\n type=\"dark\"\n label=\"Kép Választás\"\n @click=\"\n (event) => {\n selectImage(event)\n }\n \"\n />\n <Button\n type=\"danger\"\n label=\"Eltávolítás\"\n @click=\"\n (event) => {\n resetImage(event)\n }\n \"\n />\n </div>\n <dialog :id=\"imageCausationId\">\n <hvg-search-image\n :causationid=\"imageCausationId\"\n :viewid=\"imageViewId\"\n :environment=\"environment\"\n :aeurl=\"articleEditorUrl\"\n selectonly=\"true\"\n ></hvg-search-image>\n </dialog>\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"admins-components153.js","names":[],"sources":["../src/vueformelements/ArticleOfferElement.vue"],"sourcesContent":["<!-- eslint-disable-next-line vue/block-lang -->\n<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, onMounted, onUnmounted, nextTick } from 'vue'\nimport { aoeConfig } from '@/vueformelements/config/ArticleOfferElementConfig'\nimport Button from '@/components/Button.vue'\n\nexport default defineElement({\n components: { Button },\n name: 'ArticleOfferElement',\n\n setup(props, context) {\n const articleEditorUrl = aoeConfig.articleEditorUrl\n const environment = aoeConfig.environment\n const searchImageWidgetUrl = aoeConfig.searchImageWidgetUrl\n const imageBaseUrl = aoeConfig.imageBaseUrl\n const imageViewId = aoeConfig.imageViewId\n const onFetchMetaTags = aoeConfig.onFetchMetaTags\n\n const imageCausationId = ref(new Date().getTime().toString() + 'image')\n\n const EMPTYGUID = '00000000-0000-0000-0000-000000000000'\n\n const { value } = context.element\n\n const gotMetagTags = (url, imageUrl, title, lead) => {\n if (url === value.value['url']) {\n value.value.image = imageUrl\n value.value.title = title\n value.value.lead = lead\n }\n }\n\n aoeConfig.gotMetagTags = gotMetagTags\n const fetchMetaTags = () => {\n if (!value.value['url']) return\n aoeConfig.onFetchMetaTags(value.value['url'])\n }\n\n const selectImage = (event) => {\n // we need this guy, otherwise the form will be saved\n event.preventDefault()\n nextTick(() => {\n document.getElementById(imageCausationId.value).showModal()\n })\n }\n\n const resetImage = (event) => {\n event.preventDefault()\n value.value.imageId = EMPTYGUID\n value.value.image = ''\n }\n\n const addScript = (url) => {\n if (!document.querySelector(`script[src=\"${url}\"]`)) {\n const script = document.createElement('script')\n script.type = 'text/javascript'\n script.src = url\n document.head.appendChild(script)\n }\n }\n\n const ImageSelectedHandler = (e) => {\n if (e.detail.causationid == imageCausationId.value) {\n document.getElementById(imageCausationId.value).close()\n const image = e.detail.image\n value.value.image = image.url\n }\n }\n\n onUnmounted(() => {\n window.removeEventListener('image-selected', ImageSelectedHandler, false)\n })\n\n onMounted(() => {\n window.addEventListener('image-selected', ImageSelectedHandler)\n })\n\n addScript(searchImageWidgetUrl)\n\n return {\n articleEditorUrl,\n environment,\n imageViewId,\n imageBaseUrl,\n imageCausationId: imageCausationId,\n searchImageWidgetUrl,\n selectImage,\n resetImage,\n addScript,\n value,\n fetchMetaTags,\n onFetchMetaTags,\n gotMetagTags,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template v-if=\"value\" #element>\n <div class=\"ac-component\">\n <label for=\"articleUrl\" class=\"c-label\">Cikk url</label>\n <div class=\"c-input-row\">\n <input\n type=\"text\"\n id=\"articleUrl\"\n class=\"c-input\"\n placeholder=\"Cikk url\"\n :value=\"value.url\"\n @input=\"\n (event) => {\n value.url = event.target.value\n }\n \"\n @blur=\"fetchMetaTags\"\n />\n </div>\n </div>\n <div>\n <label for=\"articleTitle\" class=\"c-label\">Címe</label>\n <div class=\"c-input-row\">\n <textarea\n id=\"articleTitle\"\n class=\"c-input\"\n placeholder=\"Címe\"\n :value=\"value.title\"\n @input=\"value.title = $event.target.value\"\n ></textarea>\n </div>\n </div>\n <div>\n <label for=\"articleLead\" class=\"c-label\">Lead</label>\n <div class=\"c-input-row\">\n <textarea\n id=\"articleLead\"\n class=\"c-input\"\n placeholder=\"Lead\"\n :value=\"value.lead\"\n @input=\"value.lead = $event.target.value\"\n ></textarea>\n </div>\n </div>\n <div>\n <label class=\"c-label\" style=\"display: block\">Kép</label>\n <img\n alt=\"\"\n :src=\"value.image\"\n @input=\"value.image = $event.target.value\"\n style=\"height: 200px\"\n />\n </div>\n <div v-if=\"value.imageId === '00000000-0000-0000-0000-000000000000'\">\n Nincs kép kiválasztva!\n </div>\n <div class=\"flex-center mt-2 w-100\" role=\"group\" aria-label=\"Képválasztó gombok\">\n <Button\n type=\"dark\"\n label=\"Kép Választás\"\n @click=\"\n (event) => {\n selectImage(event)\n }\n \"\n />\n <Button\n type=\"danger\"\n label=\"Eltávolítás\"\n @click=\"\n (event) => {\n resetImage(event)\n }\n \"\n />\n </div>\n <dialog :id=\"imageCausationId\">\n <hvg-search-image\n :causationid=\"imageCausationId\"\n :viewid=\"imageViewId\"\n :environment=\"environment\"\n :aeurl=\"articleEditorUrl\"\n selectonly=\"true\"\n ></hvg-search-image>\n </dialog>\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;AAOA,IAAK,IAAa,EAAW;CAC3B,YAAY,EAAE,QAAA,EAAO;CACrB,MAAM;CAEN,MAAM,GAAO,GAAS;EACpB,IAAM,IAAmB,EAAU,kBAC7B,IAAc,EAAU,aACxB,IAAuB,EAAU,sBACjC,IAAe,EAAU,cACzB,IAAc,EAAU,aACxB,IAAkB,EAAU,iBAE5B,IAAmB,mBAAI,IAAI,KAAK,GAAE,QAAQ,EAAE,SAAS,IAAI,OAAO,GAIhE,EAAE,aAAU,EAAQ,SAEpB,KAAgB,GAAK,GAAU,GAAO,MAAS;GACnD,AAAI,MAAQ,EAAM,MAAM,QACtB,EAAM,MAAM,QAAQ,GACpB,EAAM,MAAM,QAAQ,GACpB,EAAM,MAAM,OAAO;EAEvB;EAEA,EAAU,eAAe;EACzB,IAAM,UAAsB;GACrB,EAAM,MAAM,OACjB,EAAU,gBAAgB,EAAM,MAAM,GAAM;EAC9C,GAEM,KAAe,MAAU;GAG7B,AADA,EAAM,eAAe,GACrB,QAAe;IACb,SAAS,eAAe,EAAiB,KAAK,EAAE,UAAU;GAC5D,CAAC;EACH,GAEM,KAAc,MAAU;GAG5B,AAFA,EAAM,eAAe,GACrB,EAAM,MAAM,UAAU,wCACtB,EAAM,MAAM,QAAQ;EACtB,GAEM,KAAa,MAAQ;GACzB,IAAI,CAAC,SAAS,cAAc,eAAe,EA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YAAW;;;;eAKqB,EAAA,eAApB,GAAW;QAAwB;cAI5C,CAFP,EAEO,EAAA,QAFM,GAAI,EAAG,KAAK,EAAA,IAAG,SAErB,EAAA,EAAA,GADL,EAAwC,EAAxB,CAAS,GAAA,EAAG,KAAK,EAAA,IAAG,GAAA,MAAA,GAAA,CAAA,KAAA,CAAA,EAAA,CAAA,CAAA,CAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import './src/vueformelements/ArticlePickerElement.
|
|
1
|
+
import './src/vueformelements/ArticlePickerElement.vue_vue_type_style_index_0_scoped_43c54caa_lang.css';
|
|
2
2
|
import e from "./admins-components6.js";
|
|
3
3
|
import { defineElement as t } from "./admins-components150.js";
|
|
4
4
|
import n from "./admins-components152.js";
|
|
@@ -15,7 +15,7 @@ var x = t({
|
|
|
15
15
|
e.preventDefault(), d(() => {
|
|
16
16
|
document.getElementById(m.value).showModal();
|
|
17
17
|
});
|
|
18
|
-
}, b = (
|
|
18
|
+
}, b = () => {
|
|
19
19
|
d(() => {
|
|
20
20
|
document.getElementById(g.value).showModal();
|
|
21
21
|
});
|
|
@@ -164,6 +164,6 @@ function K(e, t, n, r, i, d) {
|
|
|
164
164
|
fn: b(() => [_(e.$slots, n, { el$: e.el$ }, () => [(m(), a(y(t), { el$: e.el$ }, null, 8, ["el$"]))], !0)])
|
|
165
165
|
}))]), 1024);
|
|
166
166
|
}
|
|
167
|
-
var q = /* @__PURE__ */ n(x, [["render", K], ["__scopeId", "data-v-
|
|
167
|
+
var q = /* @__PURE__ */ n(x, [["render", K], ["__scopeId", "data-v-43c54caa"]]);
|
|
168
168
|
//#endregion
|
|
169
169
|
export { q as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components157.js","names":[],"sources":["../src/vueformelements/ArticlePickerElement.vue"],"sourcesContent":["<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, onUnmounted, onMounted, nextTick } from 'vue'\nimport { apeConfig } from '@/vueformelements/config/ArticlePickerElementConfig'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\nimport Button from '@/components/Button.vue'\n\nexport default defineElement({\n components: { Button },\n name: 'ArticlePickerElement',\n\n setup(props, context) {\n const environment = ipeConfig.environment\n const searchImageWidgetUrl = ipeConfig.searchImageWidgetUrl\n const imageBaseUrl = ipeConfig.imageBaseUrl\n const imageViewId = ipeConfig.imageViewId\n\n const searchArticleApiUrl = apeConfig.searchArticleApiUrl\n const searchArticleWidgetUrl = apeConfig.searchArticleWidgetUrl\n const showIds = apeConfig.showIds\n\n const imageCausationId = ref(new Date().getTime().toString() + 'image')\n const articleCausationId = ref(new Date().getTime().toString() + 'article')\n\n const EMPTYGUID = '00000000-0000-0000-0000-000000000000'\n\n const { value } = context.element\n\n const selectImage = (event) => {\n // we need this guy, otherwise the form will be saved\n event.preventDefault()\n\n nextTick(() => {\n document.getElementById(imageCausationId.value).showModal()\n })\n }\n\n const selectArticle = (event) => {\n nextTick(() => {\n document.getElementById(articleCausationId.value).showModal()\n })\n }\n\n const resetImage = (event) => {\n event.preventDefault()\n value.value.imageId = EMPTYGUID\n }\n\n const addScript = (url) => {\n if (!document.querySelector(`script[src=\"${url}\"]`)) {\n const script = document.createElement('script')\n script.type = 'text/javascript'\n script.src = url\n document.head.appendChild(script)\n }\n }\n\n const getImageUrl = () => {\n return `${imageBaseUrl}/${imageViewId}/${value.value.imageId}.img`\n }\n\n addScript(searchImageWidgetUrl)\n addScript(searchArticleWidgetUrl)\n\n const ImageSelectedHandler = (e) => {\n if (e.detail.causationid == imageCausationId.value) {\n document.getElementById(imageCausationId.value).close()\n value.value.imageId = e.detail.image.id\n }\n }\n\n onUnmounted(() => {\n window.removeEventListener('image-selected', ImageSelectedHandler, false)\n })\n\n onMounted(() => {\n window.addEventListener('image-selected', ImageSelectedHandler)\n\n window.addEventListener('search_posts_selected', (e) => {\n if (e.detail.id == articleCausationId.value) {\n if (e.detail.result && e.detail.posts.length > 0) {\n value.value.id = e.detail.posts[0].id\n value.value.siteId = e.detail.posts[0].siteId\n value.value.title = e.detail.posts[0].title\n value.value.lead = e.detail.posts[0].lead\n const imageId = e.detail.posts[0].featuredImage\n value.value.imageId = imageId || EMPTYGUID\n }\n\n document.getElementById(articleCausationId.value).close()\n }\n })\n })\n\n return {\n imageViewId,\n imageBaseUrl,\n imageCausationId: imageCausationId,\n articleCausationId: articleCausationId,\n searchImageWidgetUrl,\n environment,\n searchArticleApiUrl,\n selectImage,\n selectArticle,\n resetImage,\n addScript,\n value,\n getImageUrl,\n showIds,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template v-if=\"value\" #element>\n <div class=\"ac-component\">\n <div class=\"article-picker-container\">\n <div class=\"article-picker-section\">\n <Button type=\"normal\" label=\"Cikk Választás\" @click=\"selectArticle\" />\n </div>\n\n <template v-if=\"showIds\">\n <div class=\"article-picker-ids\">\n <div class=\"article-picker-id-field\">\n <label for=\"articleId\" class=\"c-label\">Cikk azonosító</label>\n <div class=\"c-input-row\">\n <input\n type=\"text\"\n id=\"articleId\"\n class=\"c-input\"\n placeholder=\"Cikk azonosító\"\n disabled\n :value=\"value.id\"\n />\n </div>\n </div>\n <div class=\"article-picker-id-field\">\n <label for=\"articleSiteId\" class=\"c-label\">Site azonosító</label>\n <div class=\"c-input-row\">\n <input\n type=\"text\"\n id=\"articleSiteId\"\n class=\"c-input\"\n placeholder=\"Site azonosító\"\n disabled\n :value=\"value.siteId\"\n />\n </div>\n </div>\n </div>\n </template>\n\n <div class=\"article-picker-section\">\n <label for=\"articleTitle\" class=\"c-label\">Címe</label>\n <div class=\"c-input-row\">\n <textarea\n id=\"articleTitle\"\n class=\"c-input\"\n placeholder=\"Címe\"\n :value=\"value.title\"\n @input=\"value.title = $event.target.value\"\n ></textarea>\n </div>\n </div>\n\n <div class=\"article-picker-section\">\n <label for=\"articleLead\" class=\"c-label\">Lead</label>\n <div class=\"c-input-row\">\n <textarea\n id=\"articleLead\"\n class=\"c-input\"\n placeholder=\"Lead\"\n :value=\"value.lead\"\n @input=\"value.lead = $event.target.value\"\n ></textarea>\n </div>\n </div>\n\n <div class=\"article-picker-section\">\n <label class=\"c-label\">Kép</label>\n <img\n alt=\"\"\n :src=\"getImageUrl()\"\n @input=\"value.image = $event.target.value\"\n class=\"article-picker-image\"\n />\n </div>\n\n <div\n v-if=\"value.imageId === '00000000-0000-0000-0000-000000000000'\"\n class=\"article-picker-no-image\"\n >\n Nincs kép kiválasztva!\n </div>\n\n <div class=\"article-picker-buttons\">\n <Button type=\"normal\" label=\"Kép Választás\" @click=\"selectImage\" />\n <Button type=\"error\" label=\"Eltávolítás\" @click=\"resetImage\" />\n </div>\n </div>\n\n <dialog :id=\"imageCausationId\">\n <hvg-search-image\n :causationid=\"imageCausationId\"\n :viewid=\"imageViewId\"\n :aeurl=\"searchArticleApiUrl\"\n :environment=\"environment\"\n selectonly=\"true\"\n ></hvg-search-image>\n </dialog>\n <dialog :id=\"articleCausationId\">\n <search-posts-widget\n :id=\"articleCausationId\"\n selector=\"true\"\n :apiurl=\"searchArticleApiUrl\"\n wpurl=\"\"\n searchurl=\"\"\n style=\"height: 100%\"\n ></search-posts-widget>\n </dialog>\n </div>\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n\n<style scoped>\n.article-picker-container {\n display: flex;\n flex-direction: column;\n gap: 1rem;\n}\n\n.article-picker-section {\n display: flex;\n flex-direction: column;\n gap: 0.375rem;\n}\n\n.article-picker-ids {\n display: flex;\n gap: 0.5rem;\n width: 100%;\n}\n\n.article-picker-id-field {\n flex: 1;\n display: flex;\n flex-direction: column;\n gap: 0.375rem;\n}\n\n.article-picker-image {\n height: 200px;\n max-width: 100%;\n border-radius: var(--ac-field-border-radius);\n object-fit: cover;\n}\n\n.article-picker-no-image {\n padding: var(--ac-input-padding);\n color: var(--neutral-500);\n font-size: var(--ac-field-font-size);\n}\n\n.article-picker-buttons {\n display: flex;\n gap: 0.5rem;\n width: 100%;\n}\n</style>\n"],"mappings":";;;;;;;;AAOA,IAAK,IAAa,EAAW;CAC3B,YAAY,EAAE,QAAA,EAAO;CACrB,MAAM;CAEN,MAAM,GAAO,GAAS;EACpB,IAAM,IAAc,EAAU,aACxB,IAAuB,EAAU,sBACjC,IAAe,EAAU,cACzB,IAAc,EAAU,aAExB,IAAsB,EAAU,qBAChC,IAAyB,EAAU,wBACnC,IAAU,EAAU,SAEpB,IAAmB,mBAAI,IAAI,KAAK,GAAE,QAAQ,EAAE,SAAS,IAAI,OAAO,GAChE,IAAqB,mBAAI,IAAI,KAAK,GAAE,QAAQ,EAAE,SAAS,IAAI,SAAS,GAEpE,IAAY,wCAEZ,EAAE,aAAU,EAAQ,SAEpB,KAAe,MAAU;GAI7B,AAFA,EAAM,eAAe,GAErB,QAAe;IACb,SAAS,eAAe,EAAiB,KAAK,EAAE,UAAU;GAC5D,CAAC;EACH,GAEM,KAAiB,MAAU;GAC/B,QAAe;IACb,SAAS,eAAe,EAAmB,KAAK,EAAE,UAAU;GAC9D,CAAC;EACH,GAEM,KAAc,MAAU;GAE5B,AADA,EAAM,eAAe,GACrB,EAAM,MAAM,UAAU;EACxB,GAEM,KAAa,MAAQ;GACzB,IAAI,CAAC,SAAS,cAAc,eAAe,EAAI,GAAG,GAAG;IACnD,IAAM,IAAS,SAAS,cAAc,QAAQ;IAG9C,AAFA,EAAO,OAAO,mBACd,EAAO,MAAM,GACb,SAAS,KAAK,YAAY,CAAM;GAClC;EACF,GAEM,UACG,GAAG,EAAa,GAAG,EAAY,GAAG,EAAM,MAAM,QAAQ;EAI/D,AADA,EAAU,CAAoB,GAC9B,EAAU,CAAsB;EAEhC,IAAM,KAAwB,MAAM;GAClC,AAAI,EAAE,OAAO,eAAe,EAAiB,UAC3C,SAAS,eAAe,EAAiB,KAAK,EAAE,M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AAG,EAAA,GAC1B,EAKE,OAAA;KAJA,KAAI;KACH,KAAK,EAAA,YAAW;KAChB,SAAK,AAAA,EAAA,QAAA,MAAE,EAAA,MAAM,QAAQ,EAAO,OAAO;KACpC,OAAM;;IAKF,EAAA,MAAM,YAAO,0CAAA,EAAA,GADrB,EAKM,OALN,GAGC,0BAED,KAAA,EAAA,IAAA,EAAA;IAEA,EAGM,OAHN,GAGM,CAFJ,EAAmE,GAAA;KAA3D,MAAK;KAAS,OAAM;KAAiB,SAAO,EAAA;8BACpD,EAA+D,GAAA;KAAvD,MAAK;KAAQ,OAAM;KAAe,SAAO,EAAA;;;GAIrD,EAQS,UAAA,EARA,IAAI,EAAA,iBAAgB,GAAA,CAC3B,EAMoB,oBAAA;IALjB,aAAa,EAAA;IACb,QAAQ,EAAA;IACR,OAAO,EAAA;IACP,aAAa,EAAA;IACd,YAAW;;GAGf,EASS,UAAA,EATA,IAAI,EAAA,mBAAkB,GAAA,CAC7B,EAOuB,uBAAA;IANpB,IAAI,EAAA;IACL,UAAS;IACR,QAAQ,EAAA;IACT,OAAM;IACN,WAAU;IACV,OAAA,EAAA,QAAA,OAAA;;;;eAM8B,EAAA,eAApB,GAAW;QAAwB;cAI5C,CAFP,EAEO,EAAA,QAFM,GAAI,EAAG,KAAK,EAAA,IAAG,SAErB,EAAA,EAAA,GADL,EAAwC,EAAxB,CAAS,GAAA,EAAG,KAAK,EAAA,IAAG,GAAA,MAAA,GAAA,CAAA,KAAA,CAAA,EAAA,GAAA,EAAA,CAAA,CAAA"}
|
|
1
|
+
{"version":3,"file":"admins-components157.js","names":[],"sources":["../src/vueformelements/ArticlePickerElement.vue"],"sourcesContent":["<!-- eslint-disable-next-line vue/block-lang -->\n<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, onUnmounted, onMounted, nextTick } from 'vue'\nimport { apeConfig } from '@/vueformelements/config/ArticlePickerElementConfig'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\nimport Button from '@/components/Button.vue'\n\nexport default defineElement({\n components: { Button },\n name: 'ArticlePickerElement',\n\n setup(props, context) {\n const environment = ipeConfig.environment\n const searchImageWidgetUrl = ipeConfig.searchImageWidgetUrl\n const imageBaseUrl = ipeConfig.imageBaseUrl\n const imageViewId = ipeConfig.imageViewId\n\n const searchArticleApiUrl = apeConfig.searchArticleApiUrl\n const searchArticleWidgetUrl = apeConfig.searchArticleWidgetUrl\n const showIds = apeConfig.showIds\n\n const imageCausationId = ref(new Date().getTime().toString() + 'image')\n const articleCausationId = ref(new Date().getTime().toString() + 'article')\n\n const EMPTYGUID = '00000000-0000-0000-0000-000000000000'\n\n const { value } = context.element\n\n const selectImage = (event) => {\n // we need this guy, otherwise the form will be saved\n event.preventDefault()\n\n nextTick(() => {\n document.getElementById(imageCausationId.value).showModal()\n })\n }\n\n const selectArticle = () => {\n nextTick(() => {\n document.getElementById(articleCausationId.value).showModal()\n })\n }\n\n const resetImage = (event) => {\n event.preventDefault()\n value.value.imageId = EMPTYGUID\n }\n\n const addScript = (url) => {\n if (!document.querySelector(`script[src=\"${url}\"]`)) {\n const script = document.createElement('script')\n script.type = 'text/javascript'\n script.src = url\n document.head.appendChild(script)\n }\n }\n\n const getImageUrl = () => {\n return `${imageBaseUrl}/${imageViewId}/${value.value.imageId}.img`\n }\n\n addScript(searchImageWidgetUrl)\n addScript(searchArticleWidgetUrl)\n\n const ImageSelectedHandler = (e) => {\n if (e.detail.causationid == imageCausationId.value) {\n document.getElementById(imageCausationId.value).close()\n value.value.imageId = e.detail.image.id\n }\n }\n\n onUnmounted(() => {\n window.removeEventListener('image-selected', ImageSelectedHandler, false)\n })\n\n onMounted(() => {\n window.addEventListener('image-selected', ImageSelectedHandler)\n\n window.addEventListener('search_posts_selected', (e) => {\n if (e.detail.id == articleCausationId.value) {\n if (e.detail.result && e.detail.posts.length > 0) {\n value.value.id = e.detail.posts[0].id\n value.value.siteId = e.detail.posts[0].siteId\n value.value.title = e.detail.posts[0].title\n value.value.lead = e.detail.posts[0].lead\n const imageId = e.detail.posts[0].featuredImage\n value.value.imageId = imageId || EMPTYGUID\n }\n\n document.getElementById(articleCausationId.value).close()\n }\n })\n })\n\n return {\n imageViewId,\n imageBaseUrl,\n imageCausationId: imageCausationId,\n articleCausationId: articleCausationId,\n searchImageWidgetUrl,\n environment,\n searchArticleApiUrl,\n selectImage,\n selectArticle,\n resetImage,\n addScript,\n value,\n getImageUrl,\n showIds,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template v-if=\"value\" #element>\n <div class=\"ac-component\">\n <div class=\"article-picker-container\">\n <div class=\"article-picker-section\">\n <Button type=\"normal\" label=\"Cikk Választás\" @click=\"selectArticle\" />\n </div>\n\n <template v-if=\"showIds\">\n <div class=\"article-picker-ids\">\n <div class=\"article-picker-id-field\">\n <label for=\"articleId\" class=\"c-label\">Cikk azonosító</label>\n <div class=\"c-input-row\">\n <input\n type=\"text\"\n id=\"articleId\"\n class=\"c-input\"\n placeholder=\"Cikk azonosító\"\n disabled\n :value=\"value.id\"\n />\n </div>\n </div>\n <div class=\"article-picker-id-field\">\n <label for=\"articleSiteId\" class=\"c-label\">Site azonosító</label>\n <div class=\"c-input-row\">\n <input\n type=\"text\"\n id=\"articleSiteId\"\n class=\"c-input\"\n placeholder=\"Site azonosító\"\n disabled\n :value=\"value.siteId\"\n />\n </div>\n </div>\n </div>\n </template>\n\n <div class=\"article-picker-section\">\n <label for=\"articleTitle\" class=\"c-label\">Címe</label>\n <div class=\"c-input-row\">\n <textarea\n id=\"articleTitle\"\n class=\"c-input\"\n placeholder=\"Címe\"\n :value=\"value.title\"\n @input=\"value.title = $event.target.value\"\n ></textarea>\n </div>\n </div>\n\n <div class=\"article-picker-section\">\n <label for=\"articleLead\" class=\"c-label\">Lead</label>\n <div class=\"c-input-row\">\n <textarea\n id=\"articleLead\"\n class=\"c-input\"\n placeholder=\"Lead\"\n :value=\"value.lead\"\n @input=\"value.lead = $event.target.value\"\n ></textarea>\n </div>\n </div>\n\n <div class=\"article-picker-section\">\n <label class=\"c-label\">Kép</label>\n <img\n alt=\"\"\n :src=\"getImageUrl()\"\n @input=\"value.image = $event.target.value\"\n class=\"article-picker-image\"\n />\n </div>\n\n <div\n v-if=\"value.imageId === '00000000-0000-0000-0000-000000000000'\"\n class=\"article-picker-no-image\"\n >\n Nincs kép kiválasztva!\n </div>\n\n <div class=\"article-picker-buttons\">\n <Button type=\"normal\" label=\"Kép Választás\" @click=\"selectImage\" />\n <Button type=\"error\" label=\"Eltávolítás\" @click=\"resetImage\" />\n </div>\n </div>\n\n <dialog :id=\"imageCausationId\">\n <hvg-search-image\n :causationid=\"imageCausationId\"\n :viewid=\"imageViewId\"\n :aeurl=\"searchArticleApiUrl\"\n :environment=\"environment\"\n selectonly=\"true\"\n ></hvg-search-image>\n </dialog>\n <dialog :id=\"articleCausationId\">\n <search-posts-widget\n :id=\"articleCausationId\"\n selector=\"true\"\n :apiurl=\"searchArticleApiUrl\"\n wpurl=\"\"\n searchurl=\"\"\n style=\"height: 100%\"\n ></search-posts-widget>\n </dialog>\n </div>\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n\n<style scoped>\n.article-picker-container {\n display: flex;\n flex-direction: column;\n gap: 1rem;\n}\n\n.article-picker-section {\n display: flex;\n flex-direction: column;\n gap: 0.375rem;\n}\n\n.article-picker-ids {\n display: flex;\n gap: 0.5rem;\n width: 100%;\n}\n\n.article-picker-id-field {\n flex: 1;\n display: flex;\n flex-direction: column;\n gap: 0.375rem;\n}\n\n.article-picker-image {\n height: 200px;\n max-width: 100%;\n border-radius: var(--ac-field-border-radius);\n object-fit: cover;\n}\n\n.article-picker-no-image {\n padding: var(--ac-input-padding);\n color: var(--neutral-500);\n font-size: var(--ac-field-font-size);\n}\n\n.article-picker-buttons {\n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A,EAAA,QAAA,MAAE,EAAA,MAAM,QAAQ,EAAO,OAAO;KACpC,OAAM;;IAKF,EAAA,MAAM,YAAO,0CAAA,EAAA,GADrB,EAKM,OALN,GAGC,0BAED,KAAA,EAAA,IAAA,EAAA;IAEA,EAGM,OAHN,GAGM,CAFJ,EAAmE,GAAA;KAA3D,MAAK;KAAS,OAAM;KAAiB,SAAO,EAAA;8BACpD,EAA+D,GAAA;KAAvD,MAAK;KAAQ,OAAM;KAAe,SAAO,EAAA;;;GAIrD,EAQS,UAAA,EARA,IAAI,EAAA,iBAAgB,GAAA,CAC3B,EAMoB,oBAAA;IALjB,aAAa,EAAA;IACb,QAAQ,EAAA;IACR,OAAO,EAAA;IACP,aAAa,EAAA;IACd,YAAW;;GAGf,EASS,UAAA,EATA,IAAI,EAAA,mBAAkB,GAAA,CAC7B,EAOuB,uBAAA;IANpB,IAAI,EAAA;IACL,UAAS;IACR,QAAQ,EAAA;IACT,OAAM;IACN,WAAU;IACV,OAAA,EAAA,QAAA,OAAA;;;;eAM8B,EAAA,eAApB,GAAW;QAAwB;cAI5C,CAFP,EAEO,EAAA,QAFM,GAAI,EAAG,KAAK,EAAA,IAAG,SAErB,EAAA,EAAA,GADL,EAAwC,EAAxB,CAAS,GAAA,EAAG,KAAK,EAAA,IAAG,GAAA,MAAA,GAAA,CAAA,KAAA,CAAA,EAAA,GAAA,EAAA,CAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components158.js","names":[],"sources":["../src/vueformelements/DateTimePickerElement.vue"],"sourcesContent":["<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, watch } from 'vue'\nimport DatePicker from '@/components/DatePicker.vue'\n\nexport default defineElement({\n name: 'DateTimePickerElement',\n components: {\n DatePicker,\n },\n setup(props, context) {\n const { value } = context.element\n value.value = new Date()\n\n const placeholder = context.attrs.placeholder\n const initial = ref(null)\n const display = ref(false)\n\n const setValue = (v) => {\n if (v && v.utc) {\n value.value = v.utc\n }\n }\n\n watch(\n value,\n () => {\n initial.value = {\n local: value.value ? new Date(value.value) : null,\n utc: value.value,\n }\n display.value = true\n },\n { deep: true, immediate: true }\n )\n\n return {\n display,\n placeholder,\n initial,\n value,\n setValue,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <DatePicker\n v-if=\"display\"\n :model-value=\"initial\"\n :config=\"{ showTime: true, placeholder: placeholder }\"\n @update:model-value=\"setValue($event)\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"admins-components158.js","names":[],"sources":["../src/vueformelements/DateTimePickerElement.vue"],"sourcesContent":["<!-- eslint-disable-next-line vue/block-lang -->\n<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, watch } from 'vue'\nimport DatePicker from '@/components/DatePicker.vue'\n\nexport default defineElement({\n name: 'DateTimePickerElement',\n components: {\n DatePicker,\n },\n setup(props, context) {\n const { value } = context.element\n value.value = new Date()\n\n const placeholder = context.attrs.placeholder\n const initial = ref(null)\n const display = ref(false)\n\n const setValue = (v) => {\n if (v && v.utc) {\n value.value = v.utc\n }\n }\n\n watch(\n value,\n () => {\n initial.value = {\n local: value.value ? new Date(value.value) : null,\n utc: value.value,\n }\n display.value = true\n },\n { deep: true, immediate: true }\n )\n\n return {\n display,\n placeholder,\n initial,\n value,\n setValue,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <DatePicker\n v-if=\"display\"\n :model-value=\"initial\"\n :config=\"{ showTime: true, placeholder: placeholder }\"\n @update:model-value=\"setValue($event)\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;AAMA,IAAK,IAAa,EAAW;CAC3B,MAAM;CACN,YAAY,EACV,YAAA,EACF;CACA,MAAM,GAAO,GAAS;EACpB,IAAM,EAAE,aAAU,EAAQ;EAC1B,EAAM,wBAAQ,IAAI,KAAK;EAEvB,IAAM,IAAc,EAAQ,MAAM,aAC5B,IAAU,EAAI,IAAI,GAClB,IAAU,EAAI,EAAK;EAoBzB,OAZA,EACE,SACM;GAKJ,AAJA,EAAQ,QAAQ;IACd,OAAO,EAAM,QAAQ,IAAI,KAAK,EAAM,KAAK,IAAI;IAC7C,KAAK,EAAM;GACb,GACA,EAAQ,QAAQ;EAClB,GACA;GAAE,MAAM;GAAM,WAAW;EAAK,CAChC,GAEO;GACL;GACA;GACA;GACA;GACA,WAvBgB,MAAM;IACtB,AAAI,KAAK,EAAE,QACT,EAAM,QAAQ,EAAE;GAEpB;EAoBA;CACF;AACF,CAAC;;;aAIC,EAgBgB,GAAA,MAAA,EAAA;EAfH,SAAO,QAMd,CAJM,EAAA,WAAA,EAAA,GADR,EAKE,GAAA;;GAHC,eAAa,EAAA;GACb,QAAM;IAAA,UAAA;IAAA,aAAiC,EAAA;GAAW;GAClD,uBAAkB,AAAA,EAAA,QAAA,MAAE,EAAA,SAAS,CAAM;;;OAIF,EAAA,eAApB,GAAW;QAAwB;cAI5C,CAFP,EAEO,EAAA,QAFM,GAAI,EAAG,KAAK,EAAA,IAAG,SAErB,EAAA,EAAA,GADL,EAAwC,EAAxB,CAAS,GAAA,EAAG,KAAK,EAAA,IAAG,GAAA,MAAA,GAAA,CAAA,KAAA,CAAA,EAAA,CAAA,CAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components16.js","names":[],"sources":["../src/components/Checkbox.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { useId } from 'vue'\n\nconst props = withDefaults(\n defineProps<{\n modelValue?: boolean\n label?: string\n disabled?: boolean\n labelAlignmentFix?: boolean\n }>(),\n {\n modelValue: undefined,\n label: undefined,\n disabled: false,\n },\n)\n\nconst emit = defineEmits<{\n 'update:modelValue': [value: boolean | undefined]\n}>()\n\nconst inputId = `c-checkbox-${useId()}`\n\nfunction
|
|
1
|
+
{"version":3,"file":"admins-components16.js","names":[],"sources":["../src/components/Checkbox.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { useId } from 'vue'\n\nconst props = withDefaults(\n defineProps<{\n modelValue?: boolean\n label?: string\n disabled?: boolean\n labelAlignmentFix?: boolean\n }>(),\n {\n modelValue: undefined,\n label: undefined,\n disabled: false,\n },\n)\n\nconst emit = defineEmits<{\n 'update:modelValue': [value: boolean | undefined]\n}>()\n\nconst inputId = `c-checkbox-${useId()}`\n\nfunction onChange(event: Event) {\n if (props.disabled) return\n\n const target = event.target as HTMLInputElement\n emit('update:modelValue', target.checked || undefined)\n}\n</script>\n\n<template>\n <div class=\"c-checkbox-wrapper\">\n <input\n type=\"checkbox\"\n class=\"c-checkbox\"\n :class=\"{\n 'c-checkbox--checked': !!modelValue,\n 'c-checkbox--disabled': disabled,\n }\"\n :id=\"inputId\"\n :checked=\"!!modelValue\"\n :disabled=\"disabled\"\n @change=\"onChange\"\n />\n<!-- :class=\"{ 'align-center-fix': labelAlignmentFix }\" -->\n <label\n v-if=\"label\"\n class=\"c-label pointer\"\n :for=\"inputId\"\n >\n {{ label }}\n </label>\n </div>\n</template>\n"],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components160.js","names":[],"sources":["../src/vueformelements/ExternalArticleOfferElement.vue"],"sourcesContent":["<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\nimport { eaoeConfig } from '@/vueformelements/config/ExternalArticleOfferElementConfig'\nimport ExternalArticleOffer from '@/components/custom/ExternalArticleOffer.vue'\n\nexport default defineElement({\n name: 'ExternalArticleOfferElement',\n components: { ExternalArticleOffer },\n\n setup(props, context) {\n const { value } = context.element\n\n return {\n ipeConfig,\n eaoeConfig,\n value,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <ExternalArticleOffer\n v-model=\"value\"\n :article-editor-url=\"ipeConfig.articleEditorUrl\"\n :environment=\"ipeConfig.environment\"\n :search-image-widget-url=\"ipeConfig.searchImageWidgetUrl\"\n :image-base-url=\"ipeConfig.imageBaseUrl\"\n :image-view-id=\"ipeConfig.imageViewId\"\n :formats=\"eaoeConfig.formats\"\n :on-article-url-changed=\"eaoeConfig.onArticleUrlChanged\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;;
|
|
1
|
+
{"version":3,"file":"admins-components160.js","names":[],"sources":["../src/vueformelements/ExternalArticleOfferElement.vue"],"sourcesContent":["<!-- eslint-disable-next-line vue/block-lang -->\n<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\nimport { eaoeConfig } from '@/vueformelements/config/ExternalArticleOfferElementConfig'\nimport ExternalArticleOffer from '@/components/custom/ExternalArticleOffer.vue'\n\nexport default defineElement({\n name: 'ExternalArticleOfferElement',\n components: { ExternalArticleOffer },\n\n setup(props, context) {\n const { value } = context.element\n\n return {\n ipeConfig,\n eaoeConfig,\n value,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <ExternalArticleOffer\n v-model=\"value\"\n :article-editor-url=\"ipeConfig.articleEditorUrl\"\n :environment=\"ipeConfig.environment\"\n :search-image-widget-url=\"ipeConfig.searchImageWidgetUrl\"\n :image-base-url=\"ipeConfig.imageBaseUrl\"\n :image-view-id=\"ipeConfig.imageViewId\"\n :formats=\"eaoeConfig.formats\"\n :on-article-url-changed=\"eaoeConfig.onArticleUrlChanged\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;;AAOA,IAAK,IAAa,EAAW;CAC3B,MAAM;CACN,YAAY,EAAE,sBAAA,EAAqB;CAEnC,MAAM,GAAO,GAAS;EACpB,IAAM,EAAE,aAAU,EAAQ;EAE1B,OAAO;GACL;GACA;GACA;EACF;CACF;AACF,CAAC;;;aAIC,EAoBgB,GAAA,MAAA,EAAA;EAnBH,SAAO,QAUd,CATF,EASE,GAAA;eARS,EAAA;0CAAA,EAAA,QAAK;GACb,sBAAoB,EAAA,UAAU;GAC9B,aAAa,EAAA,UAAU;GACvB,2BAAyB,EAAA,UAAU;GACnC,kBAAgB,EAAA,UAAU;GAC1B,iBAAe,EAAA,UAAU;GACzB,SAAS,EAAA,WAAW;GACpB,0BAAwB,EAAA,WAAW;;;;;;;;;;;;OAIF,EAAA,eAApB,GAAW;QAAwB;cAI5C,CAFP,EAEO,EAAA,QAFM,GAAI,EAAG,KAAK,EAAA,IAAG,SAErB,EAAA,EAAA,GADL,EAAwC,EAAxB,CAAS,GAAA,EAAG,KAAK,EAAA,IAAG,GAAA,MAAA,GAAA,CAAA,KAAA,CAAA,EAAA,CAAA,CAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components162.js","names":[],"sources":["../src/vueformelements/GalleryImageSelectorElement.vue"],"sourcesContent":["<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, watch } from 'vue'\nimport { gisConfig } from '@/vueformelements/config/GalleryImageSelectorElementConfig'\n\nexport default defineElement({\n name: 'GalleryImageSelectorElement',\n setup(props, context) {\n const { value } = context.element\n\n const items = ref([])\n\n const onGalleryIdChanged = (event) => {\n value.value.activeImageIndex = 0\n value.value.galleryId = event.target.value\n\n gisConfig.onFetchGallery(event.target.value, (data) => {\n items.value = data.items || []\n updateImageUrl()\n })\n }\n\n watch(\n () => value.value,\n (newVal, oldVal) => {\n if (!newVal || newVal?.galleryId === oldVal?.galleryId) {\n return\n }\n\n gisConfig.onFetchGallery(newVal?.galleryId, (data) => {\n items.value = data.items || []\n updateImageUrl()\n })\n },\n { immediate: true, deep: true },\n )\n\n const onActiveIndexChanged = (event) => {\n value.value.activeImageIndex = event.target.value\n updateImageUrl()\n }\n\n const imageUrl = ref()\n const updateImageUrl = () => {\n if (items.value && value.value.activeImageIndex >= 0) {\n const url = items.value[value.value.activeImageIndex]?.url\n imageUrl.value = url\n return\n }\n imageUrl.value = null\n }\n\n return {\n onGalleryIdChanged,\n onActiveIndexChanged,\n imageUrl,\n value,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template v-if=\"value\" #element>\n <div class=\"ac-component\">\n <div v-if=\"imageUrl\">\n <img class=\"gallery__preview\" alt=\"\" :src=\"imageUrl\" />\n </div>\n <div v-if=\"!imageUrl\">\n <p class=\"gallery__preview-empty\">Nincs kép kiválasztva!</p>\n </div>\n <div>\n <label for=\"galleryId\" class=\"c-label\">Galéria azonosító</label>\n <div class=\"c-input-row\">\n <input\n type=\"text\"\n id=\"galleryId\"\n placeholder=\"Galéria azonosító\"\n class=\"c-input\"\n :value=\"value.galleryId\"\n @input=\"(event) => onGalleryIdChanged(event)\"\n />\n </div>\n </div>\n <div>\n <label for=\"activeImageIndex\" class=\"c-label\">Aktív kép index</label>\n <div class=\"c-input-row\">\n <input\n type=\"number\"\n id=\"activeImageIndex\"\n placeholder=\"Aktív kép index\"\n class=\"c-input\"\n :value=\"value.activeImageIndex\"\n @input=\"(event) => onActiveIndexChanged(event)\"\n />\n </div>\n </div>\n </div>\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"admins-components162.js","names":[],"sources":["../src/vueformelements/GalleryImageSelectorElement.vue"],"sourcesContent":["<!-- eslint-disable-next-line vue/block-lang -->\n<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, watch } from 'vue'\nimport { gisConfig } from '@/vueformelements/config/GalleryImageSelectorElementConfig'\n\nexport default defineElement({\n name: 'GalleryImageSelectorElement',\n setup(props, context) {\n const { value } = context.element\n\n const items = ref([])\n\n const onGalleryIdChanged = (event) => {\n value.value.activeImageIndex = 0\n value.value.galleryId = event.target.value\n\n gisConfig.onFetchGallery(event.target.value, (data) => {\n items.value = data.items || []\n updateImageUrl()\n })\n }\n\n watch(\n () => value.value,\n (newVal, oldVal) => {\n if (!newVal || newVal?.galleryId === oldVal?.galleryId) {\n return\n }\n\n gisConfig.onFetchGallery(newVal?.galleryId, (data) => {\n items.value = data.items || []\n updateImageUrl()\n })\n },\n { immediate: true, deep: true },\n )\n\n const onActiveIndexChanged = (event) => {\n value.value.activeImageIndex = event.target.value\n updateImageUrl()\n }\n\n const imageUrl = ref()\n const updateImageUrl = () => {\n if (items.value && value.value.activeImageIndex >= 0) {\n const url = items.value[value.value.activeImageIndex]?.url\n imageUrl.value = url\n return\n }\n imageUrl.value = null\n }\n\n return {\n onGalleryIdChanged,\n onActiveIndexChanged,\n imageUrl,\n value,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template v-if=\"value\" #element>\n <div class=\"ac-component\">\n <div v-if=\"imageUrl\">\n <img class=\"gallery__preview\" alt=\"\" :src=\"imageUrl\" />\n </div>\n <div v-if=\"!imageUrl\">\n <p class=\"gallery__preview-empty\">Nincs kép kiválasztva!</p>\n </div>\n <div>\n <label for=\"galleryId\" class=\"c-label\">Galéria azonosító</label>\n <div class=\"c-input-row\">\n <input\n type=\"text\"\n id=\"galleryId\"\n placeholder=\"Galéria azonosító\"\n class=\"c-input\"\n :value=\"value.galleryId\"\n @input=\"(event) => onGalleryIdChanged(event)\"\n />\n </div>\n </div>\n <div>\n <label for=\"activeImageIndex\" class=\"c-label\">Aktív kép index</label>\n <div class=\"c-input-row\">\n <input\n type=\"number\"\n id=\"activeImageIndex\"\n placeholder=\"Aktív kép index\"\n class=\"c-input\"\n :value=\"value.activeImageIndex\"\n @input=\"(event) => onActiveIndexChanged(event)\"\n />\n </div>\n </div>\n </div>\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;AAMA,IAAK,IAAa,EAAW;CAC3B,MAAM;CACN,MAAM,GAAO,GAAS;EACpB,IAAM,EAAE,aAAU,EAAQ,SAEpB,IAAQ,EAAI,CAAC,CAAC,GAEd,KAAsB,MAAU;GAIpC,AAHA,EAAM,MAAM,mBAAmB,GAC/B,EAAM,MAAM,YAAY,EAAM,OAAO,OAErC,EAAU,eAAe,EAAM,OAAO,QAAQ,MAAS;IAErD,AADA,EAAM,QAAQ,EAAK,SAAS,CAAC,GAC7B,EAAe;GACjB,CAAC;EACH;EAEA,QACQ,EAAM,QACX,GAAQ,MAAW;GACd,CAAC,KAAU,GAAQ,cAAc,GAAQ,aAI7C,EAAU,eAAe,GAAQ,YAAY,MAAS;IAEpD,AADA,EAAM,QAAQ,EAAK,SAAS,CAAC,GAC7B,EAAe;GACjB,CAAC;EACH,GACA;GAAE,WAAW;GAAM,MAAM;EAAK,CAChC;EAEA,IAAM,KAAwB,MAAU;GAEtC,AADA,EAAM,MAAM,mBAAmB,EAAM,OAAO,OAC5C,EAAe;EACjB,GAEM,IAAW,EAAI,GACf,UAAuB;GAC3B,IAAI,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AAwB;cAI5C,CAFP,EAEO,EAAA,QAFM,GAAI,EAAG,KAAK,EAAA,IAAG,SAErB,EAAA,EAAA,GADL,EAAwC,EAAxB,CAAS,GAAA,EAAG,KAAK,EAAA,IAAG,GAAA,MAAA,GAAA,CAAA,KAAA,CAAA,EAAA,CAAA,CAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components163.js","names":[],"sources":["../src/vueformelements/ImagePickerElement.vue"],"sourcesContent":["<script>\nimport { defineElement } from '@vueform/vueform'\nimport ImagePicker from '@/components/custom/ImagePicker.vue'\nimport { ref, watch } from 'vue'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\n\nexport default defineElement({\n name: 'ImagePickerElement',\n components: { ImagePicker },\n\n setup(props, ctx) {\n const { value } = ctx.element // value is ref. its a string (image id) or undefined\n\n const model = ref({\n id: value.value,\n source: '',\n title: '',\n isAdult: false,\n url: '',\n })\n\n watch(\n () => value,\n (newVal) => {\n model.value.id = newVal.value\n },\n { immediate: true, deep: true },\n )\n\n return { ipeConfig, value, model }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <ImagePicker\n v-model=\"model\"\n @update:modelValue=\"(img) => (value = img?.id)\"\n :editable=\"false\"\n :details=\"false\"\n :environment=\"ipeConfig.environment\"\n :articleEditorUrl=\"ipeConfig.articleEditorUrl\"\n :searchImageWidgetUrl=\"ipeConfig.searchImageWidgetUrl\"\n :imageBaseUrl=\"ipeConfig.imageBaseUrl\"\n :imageViewId=\"ipeConfig.imageViewId\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"admins-components163.js","names":[],"sources":["../src/vueformelements/ImagePickerElement.vue"],"sourcesContent":["<!-- eslint-disable-next-line vue/block-lang -->\n<script>\nimport { defineElement } from '@vueform/vueform'\nimport ImagePicker from '@/components/custom/ImagePicker.vue'\nimport { ref, watch } from 'vue'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\n\nexport default defineElement({\n name: 'ImagePickerElement',\n components: { ImagePicker },\n\n setup(props, ctx) {\n const { value } = ctx.element // value is ref. its a string (image id) or undefined\n\n const model = ref({\n id: value.value,\n source: '',\n title: '',\n isAdult: false,\n url: '',\n })\n\n watch(\n () => value,\n (newVal) => {\n model.value.id = newVal.value\n },\n { immediate: true, deep: true },\n )\n\n return { ipeConfig, value, model }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <ImagePicker\n v-model=\"model\"\n @update:modelValue=\"(img) => (value = img?.id)\"\n :editable=\"false\"\n :details=\"false\"\n :environment=\"ipeConfig.environment\"\n :articleEditorUrl=\"ipeConfig.articleEditorUrl\"\n :searchImageWidgetUrl=\"ipeConfig.searchImageWidgetUrl\"\n :imageBaseUrl=\"ipeConfig.imageBaseUrl\"\n :imageViewId=\"ipeConfig.imageViewId\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;AAOA,IAAK,IAAa,EAAW;CAC3B,MAAM;CACN,YAAY,EAAE,aAAA,EAAY;CAE1B,MAAM,GAAO,GAAK;EAChB,IAAM,EAAE,aAAU,EAAI,SAEhB,IAAQ,EAAI;GAChB,IAAI,EAAM;GACV,QAAQ;GACR,OAAO;GACP,SAAS;GACT,KAAK;EACP,CAAC;EAUD,OARA,QACQ,IACL,MAAW;GACV,EAAM,MAAM,KAAK,EAAO;EAC1B,GACA;GAAE,WAAW;GAAM,MAAM;EAAK,CAChC,GAEO;GAAE;GAAW;GAAO;EAAM;CACnC;AACF,CAAC;;;aAIC,EAqBgB,GAAA,MAAA,EAAA;EApBH,SAAO,QAWd,CAVF,EAUE,GAAA;eATS,EAAA;2CAAA,EAAA,QAAK,GAAA,AAAA,EAAA,QACO,MAAS,EAAA,QAAQ,GAAK,EAAA;GAC1C,UAAU;GACV,SAAS;GACT,aAAa,EAAA,UAAU;GACvB,kBAAkB,EAAA,UAAU;GAC5B,sBAAsB,EAAA,UAAU;GAChC,cAAc,EAAA,UAAU;GACxB,aAAa,EAAA,UAAU;;;;;;;;;;OAIU,EAAA,eAApB,GAAW;QAAwB;cAI5C,CAFP,EAEO,EAAA,QAFM,GAAI,EAAG,KAAK,EAAA,IAAG,SAErB,EAAA,EAAA,GADL,EAAwC,EAAxB,CAAS,GAAA,EAAG,KAAK,EAAA,IAAG,GAAA,MAAA,GAAA,CAAA,KAAA,CAAA,EAAA,CAAA,CAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components164.js","names":[],"sources":["../src/vueformelements/ImagePickerDetailsElement.vue"],"sourcesContent":["<script>\nimport { defineElement } from '@vueform/vueform'\nimport { watch } from 'vue'\nimport ImagePicker from '@/components/custom/ImagePicker.vue'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\n\nexport default defineElement({\n name: 'ImagePickerDetailsElement',\n components: { ImagePicker },\n\n setup(props, context) {\n const { value } = context.element\n const direction = context.attrs.direction ? context.attrs.direction : 'vertical'\n\n watch(\n () => value,\n () => {\n if (!value.value) {\n value.value = {\n id: '00000000-0000-0000-0000-000000000000',\n source: '',\n title: '',\n isAdult: false,\n }\n }\n },\n { deep: true, immediate: true },\n )\n\n return {\n ipeConfig,\n value,\n direction,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <ImagePicker\n v-model=\"value\"\n :editable=\"true\"\n :details=\"true\"\n :direction=\"direction\"\n :environment=\"ipeConfig.environment\"\n :articleEditorUrl=\"ipeConfig.articleEditorUrl\"\n :searchImageWidgetUrl=\"ipeConfig.searchImageWidgetUrl\"\n :imageBaseUrl=\"ipeConfig.imageBaseUrl\"\n :imageViewId=\"ipeConfig.imageViewId\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"admins-components164.js","names":[],"sources":["../src/vueformelements/ImagePickerDetailsElement.vue"],"sourcesContent":["<!-- eslint-disable-next-line vue/block-lang -->\n<script>\nimport { defineElement } from '@vueform/vueform'\nimport { watch } from 'vue'\nimport ImagePicker from '@/components/custom/ImagePicker.vue'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\n\nexport default defineElement({\n name: 'ImagePickerDetailsElement',\n components: { ImagePicker },\n\n setup(props, context) {\n const { value } = context.element\n const direction = context.attrs.direction ? context.attrs.direction : 'vertical'\n\n watch(\n () => value,\n () => {\n if (!value.value) {\n value.value = {\n id: '00000000-0000-0000-0000-000000000000',\n source: '',\n title: '',\n isAdult: false,\n }\n }\n },\n { deep: true, immediate: true },\n )\n\n return {\n ipeConfig,\n value,\n direction,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <ImagePicker\n v-model=\"value\"\n :editable=\"true\"\n :details=\"true\"\n :direction=\"direction\"\n :environment=\"ipeConfig.environment\"\n :articleEditorUrl=\"ipeConfig.articleEditorUrl\"\n :searchImageWidgetUrl=\"ipeConfig.searchImageWidgetUrl\"\n :imageBaseUrl=\"ipeConfig.imageBaseUrl\"\n :imageViewId=\"ipeConfig.imageViewId\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;AAOA,IAAK,IAAa,EAAW;CAC3B,MAAM;CACN,YAAY,EAAE,aAAA,EAAY;CAE1B,MAAM,GAAO,GAAS;EACpB,IAAM,EAAE,aAAU,EAAQ,SACpB,IAAY,EAAQ,MAAM,YAAY,EAAQ,MAAM,YAAY;EAiBtE,OAfA,QACQ,SACA;GACJ,AACE,EAAM,UAAQ;IACZ,IAAI;IACJ,QAAQ;IACR,OAAO;IACP,SAAS;GACX;EAEJ,GACA;GAAE,MAAM;GAAM,WAAW;EAAK,CAChC,GAEO;GACL;GACA;GACA;EACF;CACF;AACF,CAAC;;;aAIC,EAqBgB,GAAA,MAAA,EAAA;EApBH,SAAO,QAWd,CAVF,EAUE,GAAA;eATS,EAAA;0CAAA,EAAA,QAAK;GACb,UAAU;GACV,SAAS;GACT,WAAW,EAAA;GACX,aAAa,EAAA,UAAU;GACvB,kBAAkB,EAAA,UAAU;GAC5B,sBAAsB,EAAA,UAAU;GAChC,cAAc,EAAA,UAAU;GACxB,aAAa,EAAA,UAAU;;;;;;;;;;;OAIU,EAAA,eAApB,GAAW;QAAwB;cAI5C,CAFP,EAEO,EAAA,QAFM,GAAI,EAAG,KAAK,EAAA,IAAG,SAErB,EAAA,EAAA,GADL,EAAwC,EAAxB,CAAS,GAAA,EAAG,KAAK,EAAA,IAAG,GAAA,MAAA,GAAA,CAAA,KAAA,CAAA,EAAA,CAAA,CAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components166.js","names":[],"sources":["../src/vueformelements/InternalArticleOfferElement.vue"],"sourcesContent":["<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\nimport { iaoeConfig } from '@/vueformelements/config/InternalArticleOfferElementConfig'\nimport InternalArticleOffer from '@/components/custom/InternalArticleOffer.vue'\n\nexport default defineElement({\n name: 'InternalArticleOfferElement',\n components: { InternalArticleOffer },\n\n setup(props, context) {\n const { value } = context.element\n\n return {\n ipeConfig,\n iaoeConfig,\n value,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <InternalArticleOffer\n v-model=\"value\"\n :show-ids=\"iaoeConfig.showIds\"\n :search-article-api-url=\"iaoeConfig.searchArticleApiUrl\"\n :search-article-widget-url=\"iaoeConfig.searchArticleWidgetUrl\"\n :search-image-widget-url=\"ipeConfig.searchImageWidgetUrl\"\n :image-base-url=\"ipeConfig.imageBaseUrl\"\n :environment=\"ipeConfig.environment\"\n :image-view-id=\"ipeConfig.imageViewId\"\n :formats=\"iaoeConfig.formats\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;;
|
|
1
|
+
{"version":3,"file":"admins-components166.js","names":[],"sources":["../src/vueformelements/InternalArticleOfferElement.vue"],"sourcesContent":["<!-- eslint-disable-next-line vue/block-lang -->\n<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ipeConfig } from '@/vueformelements/config/ImagePickerElementConfig'\nimport { iaoeConfig } from '@/vueformelements/config/InternalArticleOfferElementConfig'\nimport InternalArticleOffer from '@/components/custom/InternalArticleOffer.vue'\n\nexport default defineElement({\n name: 'InternalArticleOfferElement',\n components: { InternalArticleOffer },\n\n setup(props, context) {\n const { value } = context.element\n\n return {\n ipeConfig,\n iaoeConfig,\n value,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <InternalArticleOffer\n v-model=\"value\"\n :show-ids=\"iaoeConfig.showIds\"\n :search-article-api-url=\"iaoeConfig.searchArticleApiUrl\"\n :search-article-widget-url=\"iaoeConfig.searchArticleWidgetUrl\"\n :search-image-widget-url=\"ipeConfig.searchImageWidgetUrl\"\n :image-base-url=\"ipeConfig.imageBaseUrl\"\n :environment=\"ipeConfig.environment\"\n :image-view-id=\"ipeConfig.imageViewId\"\n :formats=\"iaoeConfig.formats\"\n />\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n"],"mappings":";;;;;;;AAOA,IAAK,IAAa,EAAW;CAC3B,MAAM;CACN,YAAY,EAAE,sBAAA,EAAqB;CAEnC,MAAM,GAAO,GAAS;EACpB,IAAM,EAAE,aAAU,EAAQ;EAE1B,OAAO;GACL;GACA;GACA;EACF;CACF;AACF,CAAC;;;aAIC,EAqBgB,GAAA,MAAA,EAAA;EApBH,SAAO,QAWd,CAVF,EAUE,GAAA;eATS,EAAA;0CAAA,EAAA,QAAK;GACb,YAAU,EAAA,WAAW;GACrB,0BAAwB,EAAA,WAAW;GACnC,6BAA2B,EAAA,WAAW;GACtC,2BAAyB,EAAA,UAAU;GACnC,kBAAgB,EAAA,UAAU;GAC1B,aAAa,EAAA,UAAU;GACvB,iBAAe,EAAA,UAAU;GACzB,SAAS,EAAA,WAAW;;;;;;;;;;;;;OAIa,EAAA,eAApB,GAAW;QAAwB;cAI5C,CAFP,EAEO,EAAA,QAFM,GAAI,EAAG,KAAK,EAAA,IAAG,SAErB,EAAA,EAAA,GADL,EAAwC,EAAxB,CAAS,GAAA,EAAG,KAAK,EAAA,IAAG,GAAA,MAAA,GAAA,CAAA,KAAA,CAAA,EAAA,CAAA,CAAA,CAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import './src/vueformelements/PartnerPickerElement.
|
|
1
|
+
import './src/vueformelements/PartnerPickerElement.vue_vue_type_style_index_0_scoped_09bea4ae_lang.css';
|
|
2
2
|
import { defineElement as e } from "./admins-components150.js";
|
|
3
3
|
import t from "./admins-components152.js";
|
|
4
4
|
import { ppeconfig as n } from "./admins-components167.js";
|
|
@@ -54,6 +54,6 @@ function w(e, t, n, s, f, m) {
|
|
|
54
54
|
fn: p(() => [l(e.$slots, n, { el$: e.el$ }, () => [(o(), r(d(t), { el$: e.el$ }, null, 8, ["el$"]))], !0)])
|
|
55
55
|
}))]), 1024);
|
|
56
56
|
}
|
|
57
|
-
var T = /* @__PURE__ */ t(m, [["render", w], ["__scopeId", "data-v-
|
|
57
|
+
var T = /* @__PURE__ */ t(m, [["render", w], ["__scopeId", "data-v-09bea4ae"]]);
|
|
58
58
|
//#endregion
|
|
59
59
|
export { T as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admins-components169.js","names":[],"sources":["../src/vueformelements/PartnerPickerElement.vue"],"sourcesContent":["<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, watch } from 'vue'\nimport { ppeconfig } from '@/vueformelements/config/PartnerPickerElementConfig'\n\nexport default defineElement({\n name: 'PartnerPickerElement',\n setup(props, context) {\n const { value } = context.element\n\n const logoUrl = ref('')\n const pname = ref('')\n\n watch(\n value,\n (v) => {\n if (v) {\n fetchData(v)\n }\n },\n { deep: true },\n )\n\n const onFetchData = ppeconfig.onFetchData\n\n const fetchData = (id) => {\n if (id) ppeconfig.onFetchData(id, gotData)\n }\n\n const gotData = (id, lu, nm) => {\n logoUrl.value = lu\n pname.value = nm\n\n if (value.value != id) value.value = id\n }\n\n return {\n logoUrl,\n pname,\n value,\n fetchData,\n onFetchData,\n gotData,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <div class=\"flex flex-column gap-2 ac-component\">\n <div class=\"flex gap-2 w-100\">\n <img alt=\"\" :src=\"logoUrl\" class=\"partner-logo\" />\n <div class=\"w-100\">\n <div class=\"c-input-row\">\n <input type=\"text\" class=\"c-input\" :value=\"pname\" disabled placeholder=\"Neve\" />\n </div>\n </div>\n </div>\n <div class=\"w-100\">\n <div class=\"c-input-row\">\n <input\n id=\"partner-id\"\n type=\"text\"\n class=\"c-input\"\n :value=\"value\"\n @change=\"(e) => fetchData(e.target.value)\"\n placeholder=\"Azonoító\"\n />\n </div>\n </div>\n </div>\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n\n<style scoped>\n.partner-logo {\n max-width: 25px;\n height: auto;\n flex-shrink: 0;\n}\n</style>\n"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"admins-components169.js","names":[],"sources":["../src/vueformelements/PartnerPickerElement.vue"],"sourcesContent":["<!-- eslint-disable-next-line vue/block-lang -->\n<script>\nimport { defineElement } from '@vueform/vueform'\nimport { ref, watch } from 'vue'\nimport { ppeconfig } from '@/vueformelements/config/PartnerPickerElementConfig'\n\nexport default defineElement({\n name: 'PartnerPickerElement',\n setup(props, context) {\n const { value } = context.element\n\n const logoUrl = ref('')\n const pname = ref('')\n\n watch(\n value,\n (v) => {\n if (v) {\n fetchData(v)\n }\n },\n { deep: true },\n )\n\n const onFetchData = ppeconfig.onFetchData\n\n const fetchData = (id) => {\n if (id) ppeconfig.onFetchData(id, gotData)\n }\n\n const gotData = (id, lu, nm) => {\n logoUrl.value = lu\n pname.value = nm\n\n if (value.value != id) value.value = id\n }\n\n return {\n logoUrl,\n pname,\n value,\n fetchData,\n onFetchData,\n gotData,\n }\n },\n})\n</script>\n\n<template>\n <ElementLayout>\n <template #element>\n <div class=\"flex flex-column gap-2 ac-component\">\n <div class=\"flex gap-2 w-100\">\n <img alt=\"\" :src=\"logoUrl\" class=\"partner-logo\" />\n <div class=\"w-100\">\n <div class=\"c-input-row\">\n <input type=\"text\" class=\"c-input\" :value=\"pname\" disabled placeholder=\"Neve\" />\n </div>\n </div>\n </div>\n <div class=\"w-100\">\n <div class=\"c-input-row\">\n <input\n id=\"partner-id\"\n type=\"text\"\n class=\"c-input\"\n :value=\"value\"\n @change=\"(e) => fetchData(e.target.value)\"\n placeholder=\"Azonoító\"\n />\n </div>\n </div>\n </div>\n </template>\n\n <template v-for=\"(component, slot) in elementSlots\" #[slot]>\n <!-- eslint-disable-next-line vue/valid-attribute-name -->\n <slot :name=\"slot\" :el$=\"el$\">\n <component :is=\"component\" :el$=\"el$\" />\n </slot>\n </template>\n </ElementLayout>\n</template>\n\n<style scoped>\n.partner-logo {\n max-width: 25px;\n height: auto;\n flex-shrink: 0;\n}\n</style>\n"],"mappings":";;;;;;AAMA,IAAK,IAAa,EAAW;CAC3B,MAAM;CACN,MAAM,GAAO,GAAS;EACpB,IAAM,EAAE,aAAU,EAAQ,SAEpB,IAAU,EAAI,EAAE,GAChB,IAAQ,EAAI,EAAE;EAEpB,EACE,IACC,MAAM;GACL,AAAI,KACF,EAAU,CAAC;EAEf,GACA,EAAE,MAAM,GAAK,CACf;EAEA,IAAM,IAAc,EAAU,aAExB,KAAa,MAAO;GACxB,AAAI,KAAI,EAAU,YAAY,GAAI,CAAO;EAC3C,GAEM,KAAW,GAAI,GAAI,MAAO;GAI9B,AAHA,EAAQ,QAAQ,GAChB,EAAM,QAAQ,GAEV,EAAM,SAAS,MAAI,EAAM,QAAQ;EACvC;EAEA,OAAO;GACL;GACA;GACA;GACA;GACA;GACA;EACF;CACF;AACF,CAAC,SAMU,OAAM,sCAAqC,SACzC,OAAM,mBAAkB,sBAEtB,OAAM,QAAO,SACX,OAAM,cAAa,wBAKvB,OAAM,QAAO,SACX,OAAM,cAAa;;;aAZhC,EAgCgB,GAAA,MAAA,EAAA;EA/BH,SAAO,QAsBV,CArBN,EAqBM,OArBN,GAqBM,CApBJ,EAOM,OAPN,GAOM,CANJ,EAAkD,OAAA;GAA7C,KAAI;GAAI,KAAK,EAAA;GAAS,OAAM;kBACjC,EAIM,OAJN,GAIM,CAHJ,EAEM,OAFN,GAEM,CADJ,EAAgF,SAAA;GAAzE,MAAK;GAAO,OA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