not-bulma 1.2.36 → 1.2.38
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/package.json +1 -1
- package/src/elements/form/index.js +2 -0
- package/src/elements/form/ui.control.svelte +5 -0
- package/src/elements/various/index.js +2 -0
- package/src/elements/various/ui.censored.svelte +39 -0
- package/src/elements/various/ui.select.from.model.with.search.modal.svelte +1 -1
- package/src/frame/crud/search.service.js +0 -11
- package/src/scss/_helpers.scss +7 -0
package/package.json
CHANGED
|
@@ -2,6 +2,7 @@ import UIAutocomplete from "./ui.autocomplete.svelte";
|
|
|
2
2
|
import UICheckbox from "./ui.checkbox.svelte";
|
|
3
3
|
import UICheckboxList from "./ui.checkbox.list.svelte";
|
|
4
4
|
import UIColor from "./ui.color.svelte";
|
|
5
|
+
import UIControl from "./ui.control.svelte";
|
|
5
6
|
import UIDate from "./ui.date.svelte";
|
|
6
7
|
import UIDatetimeInTZ from "./ui.datetime.in.tz.svelte";
|
|
7
8
|
import UIEmail from "./ui.email.svelte";
|
|
@@ -27,6 +28,7 @@ export {
|
|
|
27
28
|
UICheckbox,
|
|
28
29
|
UICheckboxList,
|
|
29
30
|
UIColor,
|
|
31
|
+
UIControl,
|
|
30
32
|
UIDate,
|
|
31
33
|
UIDatetimeInTZ,
|
|
32
34
|
UIEmail,
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import UIBoolean from "./ui.boolean.svelte";
|
|
2
2
|
import UIBooleanLabeled from "./ui.boolean.labeled.svelte";
|
|
3
3
|
import UIBooleans from "./ui.booleans.svelte";
|
|
4
|
+
import UICensored from "./ui.censored.svelte";
|
|
4
5
|
import UIIndicator from "./ui.indicator.svelte";
|
|
5
6
|
import UILoader from "./ui.loader.svelte";
|
|
6
7
|
import UISelectFromModelOnDemandInline from "./ui.select.from.model.on.demand.inline.svelte";
|
|
@@ -18,6 +19,7 @@ export {
|
|
|
18
19
|
UIBoolean,
|
|
19
20
|
UIBooleanLabeled,
|
|
20
21
|
UIBooleans,
|
|
22
|
+
UICensored,
|
|
21
23
|
UIErrorsList,
|
|
22
24
|
UIIndicator,
|
|
23
25
|
UILoader,
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
export let hidden = true;
|
|
3
|
+
export let showable = true;
|
|
4
|
+
export let copiable = true;
|
|
5
|
+
|
|
6
|
+
export let copyIcon = "copy";
|
|
7
|
+
export let showIcon = "eye";
|
|
8
|
+
export let hideIcon = "eye-slash";
|
|
9
|
+
|
|
10
|
+
export let value = "";
|
|
11
|
+
|
|
12
|
+
function toggleView() {
|
|
13
|
+
hidden != hidden;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
async function copyContent() {
|
|
17
|
+
try {
|
|
18
|
+
await navigator.clipboard.writeText(value);
|
|
19
|
+
} catch (err) {
|
|
20
|
+
console.error("Failed to copy: ", err);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
</script>
|
|
24
|
+
|
|
25
|
+
<span
|
|
26
|
+
class={hidden ? "is-censored has-background-primary-90" : ""}
|
|
27
|
+
style={hidden ? "width: {value.length}rem;" : ""}
|
|
28
|
+
>{hidden ? "" : value}</span
|
|
29
|
+
>
|
|
30
|
+
{#if copiable}
|
|
31
|
+
<span on:click={copyContent} class="icon is-small is-right"
|
|
32
|
+
><i class="fas fa-{copyIcon}" /></span
|
|
33
|
+
>
|
|
34
|
+
{/if}
|
|
35
|
+
{#if showable}
|
|
36
|
+
<span class="icon is-small is-right" on:click={toggleView}
|
|
37
|
+
><i class="fas fa-{hidden ? showIcon : hideIcon}" /></span
|
|
38
|
+
>
|
|
39
|
+
{/if}
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
export let serviceName = "";
|
|
27
27
|
/**
|
|
28
28
|
* Set this
|
|
29
|
-
* @property {string}
|
|
29
|
+
* @property {string} serviceOpenSelectorMethod method of service to open modal with selector
|
|
30
30
|
*/
|
|
31
31
|
export let serviceOpenSelectorMethod = "openSelector";
|
|
32
32
|
/**
|
|
@@ -24,17 +24,6 @@ export default class notServiceModelSearch {
|
|
|
24
24
|
delete this.app;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
|
-
augmentValidators(validators) {
|
|
28
|
-
return Builder(validators, () => this.getValidatorEnv());
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
getValidatorEnv() {
|
|
32
|
-
return {
|
|
33
|
-
config: this.app.getConfigReaderForModule(this.modelName),
|
|
34
|
-
validator: Validator,
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
|
|
38
27
|
getSearchRouteName() {
|
|
39
28
|
return "listAndCount";
|
|
40
29
|
}
|
package/src/scss/_helpers.scss
CHANGED