This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const image = new Image(); | |
| image.src = URL.createObjectURL(imageElement); | |
| console.info('imageElement', image.src); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const header = Machine({ | |
| id: 'header', | |
| initial: 'saved', | |
| states: { | |
| saved: {}, | |
| title: { | |
| initial: 'saved', | |
| state: { | |
| edited: {}, | |
| saved: {} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const HeaderMachine = Machine( | |
| { | |
| id: 'header', | |
| strict: true, | |
| initial: 'ready', | |
| context: { | |
| projectName: '' | |
| }, | |
| states: { | |
| ready: { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const updateMessage = (message) => assign({ message: (_, _e) => message }); | |
| const projectnameStates = { | |
| initial: 'editing', | |
| states: { | |
| editing: { | |
| entry: ['logState'], | |
| on: { | |
| PROJECT_NAME_SAVING: { | |
| target: '#headerMachine.saving', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const projectNameMachine = Machine( | |
| { | |
| id: 'project-name', | |
| strict: true, | |
| initial: 'editing', | |
| states: { | |
| editing: { | |
| on: { | |
| PROJECT_NAME_SAVING: { | |
| cond: 'validProjectName', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Simple Slider</title> | |
| </head> | |
| <body> | |
| <webui-slider></webui-slider> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const childMachine = Machine({ | |
| id: "child", | |
| initial: "step1", | |
| states: { | |
| step1: { | |
| entry: ['logState'], | |
| on: { STEP: "step2" } | |
| }, | |
| step2: { | |
| entry: ['logState'], |
OlderNewer