diff options
| author | syuilo <Syuilotan@yahoo.co.jp> | 2023-03-22 16:30:36 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-03-22 16:30:36 +0900 |
| commit | 59768bdf3f631bfbce5df3262708395757ee452e (patch) | |
| tree | bf2487ae7e5f5783a582177ef445f3aa6a4427d0 /packages/frontend/src/scripts | |
| parent | Merge pull request #10342 from misskey-dev/develop (diff) | |
| parent | Merge branch 'develop' of https://github.com/misskey-dev/misskey into develop (diff) | |
| download | misskey-59768bdf3f631bfbce5df3262708395757ee452e.tar.gz misskey-59768bdf3f631bfbce5df3262708395757ee452e.tar.bz2 misskey-59768bdf3f631bfbce5df3262708395757ee452e.zip | |
Merge pull request #10383 from misskey-dev/develop
Release: 13.10.1
Diffstat (limited to 'packages/frontend/src/scripts')
| -rw-r--r-- | packages/frontend/src/scripts/aiscript/ui.ts | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/packages/frontend/src/scripts/aiscript/ui.ts b/packages/frontend/src/scripts/aiscript/ui.ts index 6b8041d78e..2ca1b164ae 100644 --- a/packages/frontend/src/scripts/aiscript/ui.ts +++ b/packages/frontend/src/scripts/aiscript/ui.ts @@ -471,7 +471,7 @@ export function registerAsUiLib(components: Ref<AsUiComponent>[], done: (root: R components.push(component); const instance = values.OBJ(new Map([ ['id', values.STR(_id)], - ['update', values.FN_NATIVE(async ([def], opts) => { + ['update', values.FN_NATIVE(([def], opts) => { utils.assertObject(def); const updates = getOptions(def, call); for (const update of def.value.keys()) { @@ -491,13 +491,13 @@ export function registerAsUiLib(components: Ref<AsUiComponent>[], done: (root: R return { 'Ui:root': rootInstance, - 'Ui:patch': values.FN_NATIVE(async ([id, val], opts) => { + 'Ui:patch': values.FN_NATIVE(([id, val], opts) => { utils.assertString(id); utils.assertArray(val); patch(id.value, val.value, opts.call); }), - 'Ui:get': values.FN_NATIVE(async ([id], opts) => { + 'Ui:get': values.FN_NATIVE(([id], opts) => { utils.assertString(id); const instance = instances[id.value]; if (instance) { @@ -508,7 +508,7 @@ export function registerAsUiLib(components: Ref<AsUiComponent>[], done: (root: R }), // Ui:root.update({ children: [...] }) の糖衣構文 - 'Ui:render': values.FN_NATIVE(async ([children], opts) => { + 'Ui:render': values.FN_NATIVE(([children], opts) => { utils.assertArray(children); rootComponent.value.children = children.value.map(v => { @@ -517,51 +517,51 @@ export function registerAsUiLib(components: Ref<AsUiComponent>[], done: (root: R }); }), - 'Ui:C:container': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:container': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('container', def, id, getContainerOptions, opts.call); }), - 'Ui:C:text': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:text': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('text', def, id, getTextOptions, opts.call); }), - 'Ui:C:mfm': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:mfm': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('mfm', def, id, getMfmOptions, opts.call); }), - 'Ui:C:textarea': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:textarea': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('textarea', def, id, getTextareaOptions, opts.call); }), - 'Ui:C:textInput': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:textInput': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('textInput', def, id, getTextInputOptions, opts.call); }), - 'Ui:C:numberInput': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:numberInput': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('numberInput', def, id, getNumberInputOptions, opts.call); }), - 'Ui:C:button': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:button': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('button', def, id, getButtonOptions, opts.call); }), - 'Ui:C:buttons': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:buttons': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('buttons', def, id, getButtonsOptions, opts.call); }), - 'Ui:C:switch': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:switch': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('switch', def, id, getSwitchOptions, opts.call); }), - 'Ui:C:select': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:select': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('select', def, id, getSelectOptions, opts.call); }), - 'Ui:C:folder': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:folder': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('folder', def, id, getFolderOptions, opts.call); }), - 'Ui:C:postFormButton': values.FN_NATIVE(async ([def, id], opts) => { + 'Ui:C:postFormButton': values.FN_NATIVE(([def, id], opts) => { return createComponentInstance('postFormButton', def, id, getPostFormButtonOptions, opts.call); }), }; |