Rename visual actions from 'peek' to just 'open' screen in modal
This commit is contained in:
parent
bb0e76d92a
commit
33431a5edc
|
@ -19,7 +19,7 @@
|
|||
{bindings}
|
||||
/>
|
||||
<div />
|
||||
<Checkbox text="Peek screen in modal" bind:value={parameters.peek} />
|
||||
<Checkbox text="Open screen in modal" bind:value={parameters.peek} />
|
||||
</div>
|
||||
|
||||
<style>
|
||||
|
|
|
@ -6,7 +6,7 @@ import TriggerAutomation from "./TriggerAutomation.svelte"
|
|||
import ValidateForm from "./ValidateForm.svelte"
|
||||
import LogOut from "./LogOut.svelte"
|
||||
import ClearForm from "./ClearForm.svelte"
|
||||
import CloseScreenPeekModal from "./CloseScreenPeekModal.svelte"
|
||||
import CloseScreenModal from "./CloseScreenModal.svelte"
|
||||
|
||||
// Defines which actions are available to configure in the front end.
|
||||
// Unfortunately the "name" property is used as the identifier so please don't
|
||||
|
@ -49,7 +49,7 @@ export default [
|
|||
component: ClearForm,
|
||||
},
|
||||
{
|
||||
name: "Close Screen-Peek Modal",
|
||||
component: CloseScreenPeekModal,
|
||||
name: "Close Screen Modal",
|
||||
component: CloseScreenModal,
|
||||
},
|
||||
]
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
)
|
||||
// Listen for a close event to close the screen peek
|
||||
iframe.contentWindow.addEventListener(
|
||||
"close-screen-peek",
|
||||
"close-screen-modal",
|
||||
peekStore.actions.hidePeek
|
||||
)
|
||||
// Proxy notifications back to the parent window instead of iframe
|
||||
|
@ -38,7 +38,7 @@
|
|||
invalidateDataSource
|
||||
)
|
||||
iframe.contentWindow.removeEventListener(
|
||||
"close-screen-peek",
|
||||
"close-screen-modal",
|
||||
peekStore.actions.hidePeek
|
||||
)
|
||||
iframe.contentWindow.removeEventListener("notification", proxyNotification)
|
||||
|
|
|
@ -99,10 +99,10 @@ const clearFormHandler = async (action, context) => {
|
|||
)
|
||||
}
|
||||
|
||||
const closeScreenPeekModalHandler = () => {
|
||||
const closeScreenModalHandler = () => {
|
||||
// Emit this as a window event, so parent screens which are iframing us in
|
||||
// can close the modal
|
||||
window.dispatchEvent(new Event("close-screen-peek"))
|
||||
window.dispatchEvent(new Event("close-screen-modal"))
|
||||
}
|
||||
|
||||
const handlerMap = {
|
||||
|
@ -115,7 +115,7 @@ const handlerMap = {
|
|||
["Refresh Datasource"]: refreshDatasourceHandler,
|
||||
["Log Out"]: logoutHandler,
|
||||
["Clear Form"]: clearFormHandler,
|
||||
["Close Screen-Peek Modal"]: closeScreenPeekModalHandler,
|
||||
["Close Screen Modal"]: closeScreenModalHandler,
|
||||
}
|
||||
|
||||
const confirmTextMap = {
|
||||
|
|
Loading…
Reference in New Issue