aloha-vue 1.0.21 → 1.0.24
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/docs/package.json +1 -1
- package/package.json +1 -1
- package/src/AGet/AGet.js +5 -5
- package/src/AIcon/AIcon.js +2 -0
- package/src/AIcon/Icons/Pencil.js +10 -0
- package/src/AIcon/Icons/Trash.js +3 -4
- package/src/AIcon/SVG-icons/pencil.svg +6 -0
- package/src/ATable/ATableCountProPage/ATableCountProPage.js +5 -5
- package/src/ATable/ATableHeaderThAction/ATableHeaderThActionItem.js +3 -3
- package/src/ATable/ATableTopPanel/ATableTopPanel.js +3 -3
- package/src/compositionAPI/{FiltersAPI.js → AFiltersAPI.js} +19 -19
- package/src/filters/DefaultForEmpty.js +1 -1
- package/src/filters/FileSize.js +1 -1
- package/src/filters/FromNow.js +1 -1
- package/src/filters/Link.js +1 -1
- package/src/filters/currency.js +4 -4
- package/src/filters/date.js +1 -1
- package/src/filters/iban.js +1 -1
- package/src/filters/json.js +1 -1
- package/src/filters/limitTo.js +1 -1
- package/src/filters/list.js +1 -1
- package/src/filters/searchHighlight.js +1 -1
- package/src/filters/spaced.js +1 -1
- package/src/styles/components/ATable.scss +1 -1
- package/src/styles/components/ui/ui.scss +4 -0
- package/src/ui/ASelect/ASelect.js +2 -2
- package/src/ui/ASelect/ASelectElement.js +3 -3
- package/src/filters/trunc.js +0 -13
package/docs/package.json
CHANGED
package/package.json
CHANGED
package/src/AGet/AGet.js
CHANGED
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
h,
|
|
4
4
|
} from "vue";
|
|
5
5
|
|
|
6
|
-
import
|
|
6
|
+
import AFiltersAPI from "../compositionAPI/AFiltersAPI";
|
|
7
7
|
|
|
8
8
|
import {
|
|
9
9
|
forEach,
|
|
@@ -45,9 +45,9 @@ export default {
|
|
|
45
45
|
default: undefined,
|
|
46
46
|
},
|
|
47
47
|
filterParameters: {
|
|
48
|
-
type:
|
|
48
|
+
type: Object,
|
|
49
49
|
required: false,
|
|
50
|
-
default: () =>
|
|
50
|
+
default: () => {},
|
|
51
51
|
},
|
|
52
52
|
replacedWithDefault: {
|
|
53
53
|
type: [String, Number, Boolean, Array, Object, Date, Function, Symbol],
|
|
@@ -71,7 +71,7 @@ export default {
|
|
|
71
71
|
filterLink,
|
|
72
72
|
filterList,
|
|
73
73
|
filterSearchHighlight,
|
|
74
|
-
} =
|
|
74
|
+
} = AFiltersAPI();
|
|
75
75
|
|
|
76
76
|
return {
|
|
77
77
|
filterBoolean,
|
|
@@ -98,7 +98,7 @@ export default {
|
|
|
98
98
|
if (this.filter) {
|
|
99
99
|
const FILTER_FUNCTION_NAME = `filter${ capitalize(this.filter) }`;
|
|
100
100
|
if (isFunction(this[FILTER_FUNCTION_NAME])) {
|
|
101
|
-
return this[FILTER_FUNCTION_NAME](VALUE,
|
|
101
|
+
return this[FILTER_FUNCTION_NAME](VALUE, this.filterParameters);
|
|
102
102
|
}
|
|
103
103
|
console.warn(`filter "${ FILTER_FUNCTION_NAME }" ist not defined`);
|
|
104
104
|
}
|
package/src/AIcon/AIcon.js
CHANGED
|
@@ -27,6 +27,7 @@ import Minus from "./Icons/Minus";
|
|
|
27
27
|
import Ok from "./Icons/Ok";
|
|
28
28
|
import OptionHorizontal from "./Icons/OptionHorizontal";
|
|
29
29
|
import OptionVertical from "./Icons/OptionVertical";
|
|
30
|
+
import Pencil from "./Icons/Pencil";
|
|
30
31
|
import Plus from "./Icons/Plus";
|
|
31
32
|
import Reset from "./Icons/Reset";
|
|
32
33
|
import Search from "./Icons/Search";
|
|
@@ -77,6 +78,7 @@ export default {
|
|
|
77
78
|
Ok,
|
|
78
79
|
OptionHorizontal,
|
|
79
80
|
OptionVertical,
|
|
81
|
+
Pencil,
|
|
80
82
|
Plus,
|
|
81
83
|
Reset,
|
|
82
84
|
Search,
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export default `<svg
|
|
2
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
3
|
+
width="18"
|
|
4
|
+
height="18"
|
|
5
|
+
viewBox="0 0 1127 1024"
|
|
6
|
+
>
|
|
7
|
+
<path
|
|
8
|
+
d="M813.183 0.001c-69.289 0-132.274 26.991-179.062 71.984-1.808 1.808-476.907 476.005-476.907 476.005-5.396 5.396-8.995 11.695-10.793 18.901l-93.581 408.52c-2.714 13.504 0.903 26.991 10.793 36.896 7.206 7.206 17.095 11.695 27.89 11.695 2.714 0 6.302 0 8.995-0.903l407.621-94.482c7.206-1.808 13.504-5.396 18.901-10.793l470.607-470.607c0 0 0 0 0 0 47.692-47.692 77.387-112.479 77.387-184.464-0.903-145.769-117.875-262.75-261.851-262.75zM478.447 853.032l-239.353 55.788-73.783-73.783 54.888-240.253 1.808-1.808c18.901 1.808 36.896 8.995 51.29 23.392 18.901 18.901 26.096 44.092 22.491 68.385 24.298-3.59 50.391 3.59 68.385 22.491 18.901 18.901 26.096 44.092 22.491 68.385 24.298-3.59 50.391 3.59 68.385 22.491 14.401 14.401 22.491 33.295 23.392 53.090v1.808z"
|
|
9
|
+
></path>
|
|
10
|
+
</svg>`;
|
package/src/AIcon/Icons/Trash.js
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
export default `<svg
|
|
2
2
|
xmlns="http://www.w3.org/2000/svg"
|
|
3
|
-
width="
|
|
4
|
-
height="
|
|
3
|
+
width="18"
|
|
4
|
+
height="18"
|
|
5
5
|
viewBox="0 0 1024 1024"
|
|
6
6
|
>
|
|
7
7
|
<path
|
|
8
8
|
d="M398.524 364.003c0-20.634-16.703-37.332-37.288-37.332-20.587 0-37.288 16.703-37.288 37.332v452.75c0 20.587 16.703 37.252 37.288 37.252 20.587 0 37.288-16.657 37.288-37.252v-452.75zM549.312 364.003c0-20.634-16.703-37.332-37.288-37.332-20.587 0-37.288 16.703-37.288 37.332v452.75c0 20.587 16.703 37.252 37.288 37.252 20.587 0 37.288-16.657 37.288-37.252v-452.75zM700.108 364.003c0-20.634-16.748-37.332-37.332-37.332s-37.252 16.703-37.252 37.332v452.75c0 20.587 16.657 37.252 37.252 37.252s37.332-16.657 37.332-37.252v-452.75zM798.696 936.922h-573.341v-693.177h-86.988v780.254h747.344l-0.012-780.254h-86.988v693.177h-0.012zM695.021 69.66c-38.415 0-69.583-31.207-69.583-69.66h-226.834c0 38.459-31.125 69.66-69.583 69.66h-235.963v99.452h837.883v-99.452h-235.921z"
|
|
9
|
-
|
|
10
|
-
</path>
|
|
9
|
+
></path>
|
|
11
10
|
</svg>`;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="1127" height="1024" viewBox="0 0 1127 1024">
|
|
2
|
+
<title></title>
|
|
3
|
+
<g id="icomoon-ignore">
|
|
4
|
+
</g>
|
|
5
|
+
<path d="M813.183 0.001c-69.289 0-132.274 26.991-179.062 71.984-1.808 1.808-476.907 476.005-476.907 476.005-5.396 5.396-8.995 11.695-10.793 18.901l-93.581 408.52c-2.714 13.504 0.903 26.991 10.793 36.896 7.206 7.206 17.095 11.695 27.89 11.695 2.714 0 6.302 0 8.995-0.903l407.621-94.482c7.206-1.808 13.504-5.396 18.901-10.793l470.607-470.607c0 0 0 0 0 0 47.692-47.692 77.387-112.479 77.387-184.464-0.903-145.769-117.875-262.75-261.851-262.75zM478.447 853.032l-239.353 55.788-73.783-73.783 54.888-240.253 1.808-1.808c18.901 1.808 36.896 8.995 51.29 23.392 18.901 18.901 26.096 44.092 22.491 68.385 24.298-3.59 50.391 3.59 68.385 22.491 18.901 18.901 26.096 44.092 22.491 68.385 24.298-3.59 50.391 3.59 68.385 22.491 14.401 14.401 22.491 33.295 23.392 53.090v1.808z"></path>
|
|
6
|
+
</svg>
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
|
|
5
5
|
import ATranslation from "../../ATranslation/ATranslation";
|
|
6
6
|
|
|
7
|
-
import
|
|
7
|
+
import AFiltersAPI from "../../compositionAPI/AFiltersAPI";
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
export default {
|
|
@@ -46,7 +46,7 @@ export default {
|
|
|
46
46
|
setup() {
|
|
47
47
|
const {
|
|
48
48
|
filterCurrency,
|
|
49
|
-
} =
|
|
49
|
+
} = AFiltersAPI();
|
|
50
50
|
|
|
51
51
|
return {
|
|
52
52
|
filterCurrency,
|
|
@@ -62,15 +62,15 @@ export default {
|
|
|
62
62
|
},
|
|
63
63
|
|
|
64
64
|
startFormatted() {
|
|
65
|
-
return this.filterCurrency(+this.offset + 1, "", 0);
|
|
65
|
+
return this.filterCurrency(+this.offset + 1, { suffix: "", digits: 0 });
|
|
66
66
|
},
|
|
67
67
|
|
|
68
68
|
currentFormatted() {
|
|
69
|
-
return this.filterCurrency(+this.offset + this.rowsLength, "", 0);
|
|
69
|
+
return this.filterCurrency(+this.offset + this.rowsLength, { suffix: "", digits: 0 });
|
|
70
70
|
},
|
|
71
71
|
|
|
72
72
|
countFormatted() {
|
|
73
|
-
return this.filterCurrency(this.countAllRows, "", 0);
|
|
73
|
+
return this.filterCurrency(this.countAllRows, { suffix: "", digits: 0 });
|
|
74
74
|
},
|
|
75
75
|
|
|
76
76
|
countText() {
|
|
@@ -6,7 +6,7 @@ import AIcon from "../../AIcon/AIcon";
|
|
|
6
6
|
import ATranslation from "../../ATranslation/ATranslation";
|
|
7
7
|
|
|
8
8
|
import DragAndDropChildAPI from "../compositionAPI/DragAndDropChildAPI";
|
|
9
|
-
import
|
|
9
|
+
import AFiltersAPI from "../../compositionAPI/AFiltersAPI";
|
|
10
10
|
|
|
11
11
|
import {
|
|
12
12
|
setFocusToElement,
|
|
@@ -62,7 +62,7 @@ export default {
|
|
|
62
62
|
|
|
63
63
|
const {
|
|
64
64
|
filterSearchHighlight,
|
|
65
|
-
} =
|
|
65
|
+
} = AFiltersAPI();
|
|
66
66
|
|
|
67
67
|
return {
|
|
68
68
|
attributesForRoot,
|
|
@@ -168,7 +168,7 @@ export default {
|
|
|
168
168
|
},
|
|
169
169
|
|
|
170
170
|
labelLocal() {
|
|
171
|
-
return this.filterSearchHighlight(this.column.label, this.searchColumnModel);
|
|
171
|
+
return this.filterSearchHighlight(this.column.label, { searchModel: this.searchColumnModel });
|
|
172
172
|
},
|
|
173
173
|
|
|
174
174
|
isComponentVisible() {
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
import AInput from "../../ui/AInput/AInput";
|
|
6
6
|
import ATableActionItem from "../ATableActionItem/ATableActionItem";
|
|
7
7
|
|
|
8
|
-
import
|
|
8
|
+
import AFiltersAPI from "../../compositionAPI/AFiltersAPI";
|
|
9
9
|
import TableActionsAPI from "../compositionAPI/TableActionsAPI";
|
|
10
10
|
|
|
11
11
|
export default {
|
|
@@ -43,7 +43,7 @@ export default {
|
|
|
43
43
|
setup(props) {
|
|
44
44
|
const {
|
|
45
45
|
filterCurrency,
|
|
46
|
-
} =
|
|
46
|
+
} = AFiltersAPI();
|
|
47
47
|
|
|
48
48
|
const {
|
|
49
49
|
tableActionFiltered,
|
|
@@ -56,7 +56,7 @@ export default {
|
|
|
56
56
|
},
|
|
57
57
|
computed: {
|
|
58
58
|
countAllRowsFormatted() {
|
|
59
|
-
return `(${ this.filterCurrency(this.countAllRows, "", 0) })`;
|
|
59
|
+
return `(${ this.filterCurrency(this.countAllRows, { suffix: "", digits: 0 }) })`;
|
|
60
60
|
},
|
|
61
61
|
},
|
|
62
62
|
methods: {
|
|
@@ -12,57 +12,57 @@ import Link from "../filters/Link";
|
|
|
12
12
|
import list from "../filters/list";
|
|
13
13
|
import searchHighlight from "../filters/searchHighlight";
|
|
14
14
|
|
|
15
|
-
export default function
|
|
15
|
+
export default function AFiltersAPI() {
|
|
16
16
|
const filterBoolean = (value, { trueValue = "Ja", falseValue = "Nein", isNilUsed = true } = {}) => {
|
|
17
17
|
return boolean(value, { trueValue, falseValue, isNilUsed });
|
|
18
18
|
};
|
|
19
19
|
|
|
20
|
-
const filterCurrency = (value,
|
|
21
|
-
return currency(value,
|
|
20
|
+
const filterCurrency = (value, { suffix = "€", digits = 2, digitGrouping = true } = {}) => {
|
|
21
|
+
return currency(value, { suffix, digits, digitGrouping });
|
|
22
22
|
};
|
|
23
23
|
|
|
24
24
|
const filterDate = (value, param) => {
|
|
25
25
|
return date(value, param);
|
|
26
26
|
};
|
|
27
27
|
|
|
28
|
-
const filterDefaultForEmpty = (value, emptyValue = "-") => {
|
|
29
|
-
return DefaultForEmpty(value, emptyValue);
|
|
28
|
+
const filterDefaultForEmpty = (value, { emptyValue = "-" } = {}) => {
|
|
29
|
+
return DefaultForEmpty(value, { emptyValue });
|
|
30
30
|
};
|
|
31
31
|
|
|
32
32
|
const filterEmail = value => {
|
|
33
33
|
return Email(value);
|
|
34
34
|
};
|
|
35
35
|
|
|
36
|
-
const filterFileSize = (value, units) => {
|
|
37
|
-
return FileSize(value, units);
|
|
36
|
+
const filterFileSize = (value, { units } = {}) => {
|
|
37
|
+
return FileSize(value, { units });
|
|
38
38
|
};
|
|
39
39
|
|
|
40
|
-
const filterIban = (value, plain) => {
|
|
41
|
-
return iban(value, plain);
|
|
40
|
+
const filterIban = (value, { plain } = {}) => {
|
|
41
|
+
return iban(value, { plain });
|
|
42
42
|
};
|
|
43
43
|
|
|
44
|
-
const filterJson = (value, parameter = 2) => {
|
|
45
|
-
return json(value, parameter);
|
|
44
|
+
const filterJson = (value, { parameter = 2 } = {}) => {
|
|
45
|
+
return json(value, { parameter });
|
|
46
46
|
};
|
|
47
47
|
|
|
48
48
|
const filterKeyValue = value => {
|
|
49
49
|
return KeyValue(value);
|
|
50
50
|
};
|
|
51
51
|
|
|
52
|
-
const filterLimitTo = (value, param = 30) => {
|
|
53
|
-
return limitTo(value, param);
|
|
52
|
+
const filterLimitTo = (value, { param = 30 } = {}) => {
|
|
53
|
+
return limitTo(value, { param });
|
|
54
54
|
};
|
|
55
55
|
|
|
56
|
-
const filterLink = (value, param = "http://", target = "_blank") => {
|
|
57
|
-
return Link(value, param, target);
|
|
56
|
+
const filterLink = (value, { param = "http://", target = "_blank" } = {}) => {
|
|
57
|
+
return Link(value, { param, target });
|
|
58
58
|
};
|
|
59
59
|
|
|
60
|
-
const filterList = (value, isHtml = true, listClass = "list-unstyled") => {
|
|
61
|
-
return list(value, isHtml, listClass);
|
|
60
|
+
const filterList = (value, { isHtml = true, listClass = "list-unstyled" } = {}) => {
|
|
61
|
+
return list(value, { isHtml, listClass });
|
|
62
62
|
};
|
|
63
63
|
|
|
64
|
-
const filterSearchHighlight = (value, searchModel = "") => {
|
|
65
|
-
return searchHighlight(value, searchModel);
|
|
64
|
+
const filterSearchHighlight = (value, { searchModel = "" } = {}) => {
|
|
65
|
+
return searchHighlight(value, { searchModel });
|
|
66
66
|
};
|
|
67
67
|
|
|
68
68
|
return {
|
package/src/filters/FileSize.js
CHANGED
package/src/filters/FromNow.js
CHANGED
package/src/filters/Link.js
CHANGED
package/src/filters/currency.js
CHANGED
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
size,
|
|
11
11
|
} from "lodash-es";
|
|
12
12
|
|
|
13
|
-
export default function(value,
|
|
13
|
+
export default function(value, { suffix = "€", digits = 2, digitGrouping = true } = {}) {
|
|
14
14
|
if (isNil(value)) {
|
|
15
15
|
return "";
|
|
16
16
|
}
|
|
@@ -23,10 +23,10 @@ export default function(value, param = "€", digits = 2, digitGrouping = true)
|
|
|
23
23
|
valString = valString.replace(",", ".").replace(/[.](?=.*[.])/g, "");
|
|
24
24
|
let valNumber = toNumber(valString);
|
|
25
25
|
if (valNumber === 0) {
|
|
26
|
-
return `0${ digits > 0 ? "," : "" }${ repeat("0", digits) }${
|
|
26
|
+
return `0${ digits > 0 ? "," : "" }${ repeat("0", digits) }${ suffix ? ` ${ suffix }` : "" }`;
|
|
27
27
|
}
|
|
28
28
|
if (!valNumber) {
|
|
29
|
-
return `${ value }${
|
|
29
|
+
return `${ value }${ suffix ? ` ${ suffix }` : "" }`;
|
|
30
30
|
}
|
|
31
31
|
valNumber = round(valNumber, digits);
|
|
32
32
|
valString = toString(valNumber);
|
|
@@ -56,5 +56,5 @@ export default function(value, param = "€", digits = 2, digitGrouping = true)
|
|
|
56
56
|
count++;
|
|
57
57
|
antwort += val;
|
|
58
58
|
});
|
|
59
|
-
return `${ negative ? "-" : "" }${ antwort.split("").reverse().join("") }${ size(fractVal) > 0 ? "," : "" }${ fractVal }${
|
|
59
|
+
return `${ negative ? "-" : "" }${ antwort.split("").reverse().join("") }${ size(fractVal) > 0 ? "," : "" }${ fractVal }${ suffix ? ` ${ suffix }` : "" }`;
|
|
60
60
|
}
|
package/src/filters/date.js
CHANGED
package/src/filters/iban.js
CHANGED
package/src/filters/json.js
CHANGED
package/src/filters/limitTo.js
CHANGED
package/src/filters/list.js
CHANGED
package/src/filters/spaced.js
CHANGED
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
toString,
|
|
4
4
|
} from "lodash-es";
|
|
5
5
|
|
|
6
|
-
export default (value, statusNotHtml) => {
|
|
6
|
+
export default (value, { statusNotHtml } = {}) => {
|
|
7
7
|
const FORMAT = store.getters["syConfigs/GET_VALUE"]("antragsnummerformat");
|
|
8
8
|
return setStrInFormat({ format: FORMAT, value, statusNotHtml });
|
|
9
9
|
};
|
|
@@ -430,13 +430,13 @@ export default {
|
|
|
430
430
|
}, [
|
|
431
431
|
h("span", null, index !== 0 ? ", " : ""),
|
|
432
432
|
h(ASelectLabelElement, {
|
|
433
|
-
data: this.dataKeyByKeyIdLocal[item],
|
|
433
|
+
data: this.dataKeyByKeyIdLocal[item] || {},
|
|
434
434
|
}),
|
|
435
435
|
]);
|
|
436
436
|
}),
|
|
437
437
|
]) :
|
|
438
438
|
h(ASelectLabelElement, {
|
|
439
|
-
data: this.dataKeyByKeyIdLocal[this.modelValue],
|
|
439
|
+
data: this.dataKeyByKeyIdLocal[this.modelValue] || {},
|
|
440
440
|
class: "a_select__value__label",
|
|
441
441
|
})
|
|
442
442
|
: "",
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
|
|
7
7
|
import AIcon from "../../AIcon/AIcon";
|
|
8
8
|
|
|
9
|
-
import
|
|
9
|
+
import AFiltersAPI from "../../compositionAPI/AFiltersAPI";
|
|
10
10
|
|
|
11
11
|
import AKeyId from "../const/AKeyId";
|
|
12
12
|
import AKeyLabel from "../const/AKeyLabel";
|
|
@@ -51,7 +51,7 @@ export default {
|
|
|
51
51
|
setup(props, { emit }) {
|
|
52
52
|
const {
|
|
53
53
|
filterSearchHighlight,
|
|
54
|
-
} =
|
|
54
|
+
} = AFiltersAPI();
|
|
55
55
|
|
|
56
56
|
const data = toRef(props, "data");
|
|
57
57
|
const modelSearch = toRef(props, "modelSearch");
|
|
@@ -65,7 +65,7 @@ export default {
|
|
|
65
65
|
});
|
|
66
66
|
|
|
67
67
|
const currentLabelFiltered = computed(() => {
|
|
68
|
-
return filterSearchHighlight(currentLabel.value, modelSearch.value);
|
|
68
|
+
return filterSearchHighlight(currentLabel.value, { searchModel: modelSearch.value });
|
|
69
69
|
});
|
|
70
70
|
|
|
71
71
|
const isMultiselect = toRef(props, "isMultiselect");
|
package/src/filters/trunc.js
DELETED