mirror of
https://github.com/smartyellow/status.git
synced 2025-01-18 05:27:58 +00:00
Events
This commit is contained in:
parent
c5658c872e
commit
dbe3648545
@ -34,8 +34,8 @@ const defaultHeader = {
|
|||||||
value: '',
|
value: '',
|
||||||
};
|
};
|
||||||
|
|
||||||
const changeValue = () => dispatch('changeValue', value) && console.log(value);;
|
const changeValue = e => dispatch('changeValue', value) && e.target.focus();
|
||||||
const appendEndpoint = () => value = [...value, defaultEndpoint];
|
const appendEndpoint = () => value = [ ...value, defaultEndpoint ];
|
||||||
|
|
||||||
function removeEndpoint(i) {
|
function removeEndpoint(i) {
|
||||||
value.splice(i, 1);
|
value.splice(i, 1);
|
||||||
@ -146,9 +146,7 @@ function removeEndpoint(i) {
|
|||||||
bind:value={req.type}
|
bind:value={req.type}
|
||||||
disabled={readonly}
|
disabled={readonly}
|
||||||
on:focus
|
on:focus
|
||||||
on:keyup={changeValue}
|
|
||||||
on:change={changeValue}
|
on:change={changeValue}
|
||||||
on:blur={changeValue}
|
|
||||||
>
|
>
|
||||||
{#each Object.keys(realValueNames) as valName}
|
{#each Object.keys(realValueNames) as valName}
|
||||||
<option value={valName}>{realValueNames[valName]}</option>
|
<option value={valName}>{realValueNames[valName]}</option>
|
||||||
@ -176,9 +174,7 @@ function removeEndpoint(i) {
|
|||||||
bind:value={req.operator}
|
bind:value={req.operator}
|
||||||
disabled={readonly}
|
disabled={readonly}
|
||||||
on:focus
|
on:focus
|
||||||
on:keyup={changeValue}
|
|
||||||
on:change={changeValue}
|
on:change={changeValue}
|
||||||
on:blur={changeValue}
|
|
||||||
>
|
>
|
||||||
{#each Object.keys(operatorNames) as opName}
|
{#each Object.keys(operatorNames) as opName}
|
||||||
<option value={opName}>{operatorNames[opName]}</option>
|
<option value={opName}>{operatorNames[opName]}</option>
|
||||||
|
Loading…
Reference in New Issue
Block a user