Add multiline field plugins (#974)
* Update schema * Add multiline field to plugins * Update changelog * Update stories * Update stories * -Trigger CI
This commit is contained in:
parent
a3fd4bb6c2
commit
06266575b2
4 changed files with 128 additions and 0 deletions
|
@ -30,6 +30,7 @@ All notable, unreleased changes to this project will be documented in this file.
|
|||
- Remove mailing settings - #1027 by @dominik-zeglen
|
||||
- Update schema to contain email plugin changes - #1029 by @dominik-zeglen
|
||||
- Unconfirmed order manipulation - #967 by @tomaszszymanski129
|
||||
- Add multiline field plugins - #974 by @dominik-zeglen
|
||||
|
||||
# 2.11.1
|
||||
|
||||
|
|
|
@ -107,6 +107,12 @@ const PluginSettings: React.FC<PluginSettingsProps> = ({
|
|||
helperText={fieldData.helpText}
|
||||
label={fieldData.label}
|
||||
name={field.name}
|
||||
multiline={
|
||||
fieldData.type === ConfigurationTypeFieldEnum.MULTILINE
|
||||
}
|
||||
InputProps={{
|
||||
rowsMax: 6
|
||||
}}
|
||||
fullWidth
|
||||
value={field.value}
|
||||
onChange={onChange}
|
||||
|
|
|
@ -72,6 +72,15 @@ export const plugin: Plugin_plugin = {
|
|||
name: "Use sandbox",
|
||||
type: ConfigurationTypeFieldEnum.BOOLEAN,
|
||||
value: "true"
|
||||
},
|
||||
{
|
||||
__typename: "ConfigurationItem",
|
||||
helpText: "This is a multiline field",
|
||||
label: "Multiline Field",
|
||||
name: "multiline-field",
|
||||
type: ConfigurationTypeFieldEnum.MULTILINE,
|
||||
value:
|
||||
"Lorem ipsum\ndolor sit\namet enim.\nEtiam ullamcorper.\nSuspendisse a\npellentesque dui,\nnon felis."
|
||||
}
|
||||
],
|
||||
description:
|
||||
|
|
|
@ -146671,6 +146671,62 @@ exports[`Storyshots Views / Plugins / Plugin details default 1`] = `
|
|||
/>
|
||||
</svg>
|
||||
</div>
|
||||
<div
|
||||
class="PluginSettings-item-id"
|
||||
>
|
||||
<div
|
||||
class="MuiFormControl-root-id MuiTextField-root-id MuiFormControl-fullWidth-id"
|
||||
>
|
||||
<label
|
||||
class="MuiFormLabel-root-id MuiInputLabel-root-id MuiInputLabel-formControl-id MuiInputLabel-animated-id MuiInputLabel-shrink-id MuiInputLabel-outlined-id MuiFormLabel-filled-id"
|
||||
data-shrink="true"
|
||||
>
|
||||
Multiline Field
|
||||
</label>
|
||||
<div
|
||||
class="MuiInputBase-root-id MuiOutlinedInput-root-id MuiInputBase-fullWidth-id MuiInputBase-formControl-id MuiInputBase-multiline-id MuiOutlinedInput-multiline-id"
|
||||
>
|
||||
<textarea
|
||||
aria-invalid="false"
|
||||
class="MuiInputBase-input-id MuiOutlinedInput-input-id MuiInputBase-inputMultiline-id MuiOutlinedInput-inputMultiline-id"
|
||||
name="multiline-field"
|
||||
rows="1"
|
||||
>
|
||||
Lorem ipsum
|
||||
dolor sit
|
||||
amet enim.
|
||||
Etiam ullamcorper.
|
||||
Suspendisse a
|
||||
pellentesque dui,
|
||||
non felis.
|
||||
</textarea>
|
||||
<textarea
|
||||
aria-hidden="true"
|
||||
class="MuiInputBase-input-id MuiOutlinedInput-input-id MuiInputBase-inputMultiline-id MuiOutlinedInput-inputMultiline-id"
|
||||
readonly=""
|
||||
style="visibility:hidden;position:absolute;overflow:hidden;height:0;top:0;left:0;transform:translateZ(0)"
|
||||
tabindex="-1"
|
||||
/>
|
||||
<fieldset
|
||||
aria-hidden="true"
|
||||
class="PrivateNotchedOutline-root-id MuiOutlinedInput-notchedOutline-id"
|
||||
>
|
||||
<legend
|
||||
class="PrivateNotchedOutline-legendLabelled-id PrivateNotchedOutline-legendNotched-id"
|
||||
>
|
||||
<span>
|
||||
Multiline Field
|
||||
</span>
|
||||
</legend>
|
||||
</fieldset>
|
||||
</div>
|
||||
<p
|
||||
class="MuiFormHelperText-root-id MuiFormHelperText-contained-id MuiFormHelperText-filled-id"
|
||||
>
|
||||
This is a multiline field
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
|
@ -147134,6 +147190,62 @@ exports[`Storyshots Views / Plugins / Plugin details form errors 1`] = `
|
|||
/>
|
||||
</svg>
|
||||
</div>
|
||||
<div
|
||||
class="PluginSettings-item-id"
|
||||
>
|
||||
<div
|
||||
class="MuiFormControl-root-id MuiTextField-root-id MuiFormControl-fullWidth-id"
|
||||
>
|
||||
<label
|
||||
class="MuiFormLabel-root-id MuiInputLabel-root-id MuiInputLabel-formControl-id MuiInputLabel-animated-id MuiInputLabel-shrink-id MuiInputLabel-outlined-id MuiFormLabel-filled-id"
|
||||
data-shrink="true"
|
||||
>
|
||||
Multiline Field
|
||||
</label>
|
||||
<div
|
||||
class="MuiInputBase-root-id MuiOutlinedInput-root-id MuiInputBase-fullWidth-id MuiInputBase-formControl-id MuiInputBase-multiline-id MuiOutlinedInput-multiline-id"
|
||||
>
|
||||
<textarea
|
||||
aria-invalid="false"
|
||||
class="MuiInputBase-input-id MuiOutlinedInput-input-id MuiInputBase-inputMultiline-id MuiOutlinedInput-inputMultiline-id"
|
||||
name="multiline-field"
|
||||
rows="1"
|
||||
>
|
||||
Lorem ipsum
|
||||
dolor sit
|
||||
amet enim.
|
||||
Etiam ullamcorper.
|
||||
Suspendisse a
|
||||
pellentesque dui,
|
||||
non felis.
|
||||
</textarea>
|
||||
<textarea
|
||||
aria-hidden="true"
|
||||
class="MuiInputBase-input-id MuiOutlinedInput-input-id MuiInputBase-inputMultiline-id MuiOutlinedInput-inputMultiline-id"
|
||||
readonly=""
|
||||
style="visibility:hidden;position:absolute;overflow:hidden;height:0;top:0;left:0;transform:translateZ(0)"
|
||||
tabindex="-1"
|
||||
/>
|
||||
<fieldset
|
||||
aria-hidden="true"
|
||||
class="PrivateNotchedOutline-root-id MuiOutlinedInput-notchedOutline-id"
|
||||
>
|
||||
<legend
|
||||
class="PrivateNotchedOutline-legendLabelled-id PrivateNotchedOutline-legendNotched-id"
|
||||
>
|
||||
<span>
|
||||
Multiline Field
|
||||
</span>
|
||||
</legend>
|
||||
</fieldset>
|
||||
</div>
|
||||
<p
|
||||
class="MuiFormHelperText-root-id MuiFormHelperText-contained-id MuiFormHelperText-filled-id"
|
||||
>
|
||||
This is a multiline field
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
|
|
Loading…
Reference in a new issue