Add password field component

This commit is contained in:
Andrew Kingston 2021-03-01 14:13:11 +00:00
parent a3e959daa8
commit 78865ddef4
4 changed files with 35 additions and 0 deletions

View File

@ -12,6 +12,7 @@
"fieldgroup", "fieldgroup",
"stringfield", "stringfield",
"numberfield", "numberfield",
"passwordfield",
"optionsfield", "optionsfield",
"booleanfield", "booleanfield",
"longformfield", "longformfield",

View File

@ -1295,6 +1295,34 @@
} }
] ]
}, },
"passwordfield": {
"name": "Password Field",
"icon": "ri-lock-password-line",
"styleable": true,
"settings": [
{
"type": "field/string",
"label": "Field",
"key": "field"
},
{
"type": "text",
"label": "Label",
"key": "label"
},
{
"type": "text",
"label": "Placeholder",
"key": "placeholder"
},
{
"type": "boolean",
"label": "Disabled",
"key": "disabled",
"defaultValue": false
}
]
},
"optionsfield": { "optionsfield": {
"name": "Options Picker", "name": "Options Picker",
"icon": "ri-file-list-line", "icon": "ri-file-list-line",

View File

@ -0,0 +1,5 @@
<script>
import StringField from "./StringField.svelte"
</script>
<StringField {...$$props} type="password" />

View File

@ -8,3 +8,4 @@ export { default as longformfield } from "./LongFormField.svelte"
export { default as datetimefield } from "./DateTimeField.svelte" export { default as datetimefield } from "./DateTimeField.svelte"
export { default as attachmentfield } from "./AttachmentField.svelte" export { default as attachmentfield } from "./AttachmentField.svelte"
export { default as relationshipfield } from "./RelationshipField.svelte" export { default as relationshipfield } from "./RelationshipField.svelte"
export { default as passwordfield } from "./PasswordField.svelte"