vue3-extended-multiselect 1.5.6 → 1.5.8
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/.browserslistrc +1 -1
- package/CHANGELOG.md +10 -2
- package/CONTRIBUTING.md +57 -0
- package/README.md +1 -1
- package/jest.config.js +1 -1
- package/package.json +1 -1
- package/src/components/ExtendedMultiselectToggle.vue +2 -3
- package/src/components/Vue3ExtendedMultiselect.vue +3 -7
- package/src/composition/toggle.js +2 -2
package/.browserslistrc
CHANGED
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Patch notes
|
|
2
2
|
|
|
3
|
-
Current `vue3-extended-multiselect` version: **1.5.
|
|
3
|
+
Current `vue3-extended-multiselect` version: **1.5.8**
|
|
4
4
|
|
|
5
5
|
***
|
|
6
6
|
|
|
@@ -217,4 +217,12 @@ Adding descriptive comments for some types in typings.
|
|
|
217
217
|
### 1.5.6 (2023-01-26)
|
|
218
218
|
|
|
219
219
|
* Fixing bug with "noOption" slot being displayed when search field value is not empty.
|
|
220
|
-
* Fixing bug with reload of preselected options when using external loader.
|
|
220
|
+
* Fixing bug with reload of preselected options when using external loader.
|
|
221
|
+
|
|
222
|
+
### 1.5.7 (2023-01-26)
|
|
223
|
+
|
|
224
|
+
* Removal of internal loading state because of using "lodash.debounce".
|
|
225
|
+
|
|
226
|
+
### 1.5.8 (2023-01-01)
|
|
227
|
+
|
|
228
|
+
* Adding CONTRIBUTING.md file.
|
package/CONTRIBUTING.md
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# Contributing to vue3-extended-multiselect
|
|
2
|
+
|
|
3
|
+
First off, thanks for taking the time to contribute! ❤️
|
|
4
|
+
|
|
5
|
+
All types of contributions are encouraged and valued. Please make sure to read the relevant section before making your contribution. It will make it a lot easier for us maintainers and smooth out the experience for all involved. The community looks forward to your contributions. 🎉
|
|
6
|
+
|
|
7
|
+
> And if you like the project, but just don't have time to contribute, that's fine. There are other easy ways to support the project and show your appreciation, which i would also be very happy about:
|
|
8
|
+
> - Star the project
|
|
9
|
+
> - Start watching this project
|
|
10
|
+
> - Refer this project in your project's readme
|
|
11
|
+
> - Mention the project at local meetups and tell your friends/colleagues
|
|
12
|
+
|
|
13
|
+
## You Have a Question
|
|
14
|
+
|
|
15
|
+
> If you want to ask a question, i assume that you have read the available [Documentation](https://github.com/danyaridiger/vue3-extended-multiselect/blob/master/README.md).
|
|
16
|
+
|
|
17
|
+
Before you ask a question, it is best to search for existing [Issues](https://github.com/danyaridiger/vue3-extended-multiselect/issues) that might help you. In case you have found a suitable issue and still need clarification, you can write your question in this issue. It is also advisable to search the internet for answers first.
|
|
18
|
+
|
|
19
|
+
If you then still feel the need to ask a question and need clarification, i recommend the following:
|
|
20
|
+
|
|
21
|
+
- Open an [Issue](https://github.com/danyaridiger/vue3-extended-multiselect/issues/new).
|
|
22
|
+
- Provide as much context as you can about what you're running into.
|
|
23
|
+
- Provide project and platform versions (nodejs, npm, etc), depending on what seems relevant.
|
|
24
|
+
|
|
25
|
+
I will then take care of the issue as soon as possible.
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
## You Want To Contribute
|
|
29
|
+
|
|
30
|
+
> ### Legal Notice
|
|
31
|
+
> When contributing to this project, you must agree that you have authored 100% of the content, that you have the necessary rights to the content and that the content you contribute may be provided under the project license.
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
### Suggesting Enhancements
|
|
35
|
+
|
|
36
|
+
This section guides you through submitting an enhancement suggestion for **vue3-extended-multiselect**, including completely new features and minor improvements to existing functionality. Following these guidelines will help maintainers and the community to understand your suggestion and find related suggestions.
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
#### Before Submitting an Enhancement
|
|
40
|
+
|
|
41
|
+
- Make sure that you are using the latest version.
|
|
42
|
+
- Read the [documentation](https://github.com/danyaridiger/vue3-extended-multiselect/blob/master/README.md) carefully and find out if the functionality is already covered, maybe by an individual configuration.
|
|
43
|
+
- Perform a [search](https://github.com/danyaridiger/vue3-extended-multiselect/issues) to see if the enhancement has already been suggested. If it has, add a comment to the existing issue instead of opening a new one.
|
|
44
|
+
- Find out whether your idea fits with the scope and aims of the project. It's up to you to make a strong case to convince the project's developers of the merits of this feature. Keep in mind that i want features that will be useful to the majority of our users and not just a small subset. If you're just targeting a minority of users, consider writing an add-on/plugin library.
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
#### How Do You Submit a Good Enhancement Suggestion?
|
|
48
|
+
|
|
49
|
+
Enhancement suggestions are tracked as [GitHub issues](https://github.com/danyaridiger/vue3-extended-multiselect/issues).
|
|
50
|
+
|
|
51
|
+
- Use a **clear and descriptive title** for the issue to identify the suggestion.
|
|
52
|
+
- Provide a **step-by-step description of the suggested enhancement** in as many details as possible.
|
|
53
|
+
- **Describe the current behavior** and **explain which behavior you expected to see instead** and why. At this point you can also tell which alternatives do not work for you.
|
|
54
|
+
- You may want to **include screenshots and animated GIFs** which help you demonstrate the steps or point out the part which the suggestion is related to.
|
|
55
|
+
- **Explain why this enhancement would be useful** to most **vue3-extended-multiselect** users. You may also want to point out the other projects that solved it better and which could serve as inspiration.
|
|
56
|
+
|
|
57
|
+
|
package/README.md
CHANGED
package/jest.config.js
CHANGED
package/package.json
CHANGED
|
@@ -180,9 +180,8 @@ const {
|
|
|
180
180
|
const { createImagePath } = useImagePath();
|
|
181
181
|
|
|
182
182
|
const { toggleSlotClass, toggleOptionsList } = useToggle(
|
|
183
|
-
loading,
|
|
184
|
-
disabled,
|
|
185
|
-
null,
|
|
183
|
+
loading,
|
|
184
|
+
disabled,
|
|
186
185
|
emitter,
|
|
187
186
|
);
|
|
188
187
|
const { iconSizeClass } = useSizes(iconSize);
|
|
@@ -252,8 +252,8 @@ import ExtendedMultiselectOptions from "./ExtendedMultiselectOptions.vue";
|
|
|
252
252
|
import ExtendedMultiselectToggle from "./ExtendedMultiselectToggle.vue";
|
|
253
253
|
|
|
254
254
|
/**
|
|
255
|
-
* @author Ridiger Daniil Dmitrievich
|
|
256
|
-
* @version 1.5.
|
|
255
|
+
* @author Ridiger Daniil Dmitrievich, 2022
|
|
256
|
+
* @version 1.5.8
|
|
257
257
|
*/
|
|
258
258
|
|
|
259
259
|
const props = defineProps({
|
|
@@ -886,7 +886,6 @@ const emit = defineEmits([
|
|
|
886
886
|
|
|
887
887
|
const dropdownActive = ref(false);
|
|
888
888
|
const inputDisabled = ref(false);
|
|
889
|
-
const internalLoader = ref(false);
|
|
890
889
|
const externalOptionsLoader = ref(null);
|
|
891
890
|
const chosenToggleAppearanceSide = ref(null);
|
|
892
891
|
const rawOptions = ref([]);
|
|
@@ -943,7 +942,6 @@ const { emitter } = useEmitter();
|
|
|
943
942
|
const { toggleOptionsList } = useToggle(
|
|
944
943
|
loading,
|
|
945
944
|
disabled,
|
|
946
|
-
internalLoader,
|
|
947
945
|
emitter,
|
|
948
946
|
);
|
|
949
947
|
const { cancel } = useCancel(
|
|
@@ -1065,7 +1063,7 @@ const expanded = computed(() => {
|
|
|
1065
1063
|
* @returns {boolean} loading
|
|
1066
1064
|
*/
|
|
1067
1065
|
const internalLoading = computed(() => {
|
|
1068
|
-
return loading.value
|
|
1066
|
+
return loading.value;
|
|
1069
1067
|
});
|
|
1070
1068
|
|
|
1071
1069
|
/**
|
|
@@ -1272,11 +1270,9 @@ const fieldFocus = (mouseEvent) => {
|
|
|
1272
1270
|
* @param {boolean} initialValue - preselected options flag
|
|
1273
1271
|
*/
|
|
1274
1272
|
const loadOptionsByExternalLoader = (pattern, initialValue) => {
|
|
1275
|
-
internalLoader.value = true;
|
|
1276
1273
|
externalOptionsLoader.value = options.value;
|
|
1277
1274
|
options.value(pattern).then(options => {
|
|
1278
1275
|
rawOptions.value = options;
|
|
1279
|
-
internalLoader.value = false;
|
|
1280
1276
|
if (initialValue) setPreselectedOptionsByConditions();
|
|
1281
1277
|
});
|
|
1282
1278
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { computed, readonly } from "vue";
|
|
2
2
|
|
|
3
|
-
export default function useToggle(loading, disabled,
|
|
3
|
+
export default function useToggle(loading, disabled, emitter) {
|
|
4
4
|
/**
|
|
5
5
|
* Toggles classes of slots if "loading"
|
|
6
6
|
* or "disabled" props equals true
|
|
@@ -8,7 +8,7 @@ export default function useToggle(loading, disabled, internalLoader, emitter) {
|
|
|
8
8
|
* @returns {string} class
|
|
9
9
|
*/
|
|
10
10
|
const toggleSlotClass = computed(() => {
|
|
11
|
-
return loading.value || disabled.value
|
|
11
|
+
return loading.value || disabled.value
|
|
12
12
|
? "extended__multiselect-toggle--disabled"
|
|
13
13
|
: "extended__multiselect-toggle";
|
|
14
14
|
});
|