Skip to content

Commit

Permalink
Start connecting state logic
Browse files Browse the repository at this point in the history
  • Loading branch information
vgeorge committed Feb 5, 2024
1 parent d170bef commit 70933dd
Show file tree
Hide file tree
Showing 4 changed files with 162 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ const MosaicOption = styled(Option)`
`;

export function MosaicSelector() {
const actorRef = ProjectMachineContext.useActorRef();
const [showModal, setShowModal] = useState(false);

const sessionMode = ProjectMachineContext.useSelector(selectors.sessionMode);
Expand Down Expand Up @@ -157,13 +158,13 @@ export function MosaicSelector() {
.map((t) => (
<MosaicOption
key={t.id}
// disabled={disabled}
// onClick={async () => {
// actorRef.send({
// type: 'Apply timeframe',
// data: { timeframe: { ...t } },
// });
// }}
disabled={disabled}
onClick={async () => {
actorRef.send({
type: 'Apply timeframe',
data: { timeframe: { ...t } },
});
}}
>
<Heading size='xsmall'>{t.label}</Heading>
</MosaicOption>
Expand Down
6 changes: 6 additions & 0 deletions app/assets/scripts/fsm/project/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -454,6 +454,12 @@ export const actions = {
disabled: false,
},
})),
enterApplyTimeframe: assign(() => ({
sessionStatusMessage: 'Applying timeframe',
globalLoading: {
disabled: false,
},
})),
exitRetrainMode: assign((context) => {
const { freehandDraw, polygonDraw } = context.mapRef;

Expand Down
22 changes: 21 additions & 1 deletion app/assets/scripts/fsm/project/machine.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { SESSION_MODES } from './constants';

export const projectMachine = createMachine(
{
/** @xstate-layout N4IgpgJg5mDOIC5QAcBOB7AVmAxgFwFoBbAQxwAsBLAOzADoAFEmAAkthaPQFdq9IAxACU46ADYA3MCxLc85MH0o4SeSumoBtAAwBdRCnSxKajQZAAPRAQCMNgMwB2OnYCcAVkcAOLwDYnvl7uADQgAJ6INv50jo6uAEwevq7JTu4ALAC+maFoWLiEpBQ09Eys7CyoYCQQYQI6+kggyEYm6tTmVgi2dvF06Tbu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xkCfkJzacWfW8AlE583giNiGH94-4+gtIbIqSG7Ly8h8jY2fC4gCAmRqOdnBzNYLADP8yhKsRbpyIGCZhtwQ1bBDyHHJUCsShIj7uVw7SpjPAzgFNhuEyJid7eQON8SXEeiggFEZ40pJNxlDTdlATAxII2JGQg4raI0eWBsFqYAoXoWkdsWwkO4thjuAPP3oBKS6K9Q60uK3ByBuG3clwAhaDEOQ3AIdsgmQIAA */
predictableActionArguments: true,
id: 'project-machine',
initial: 'Page is mounted',
Expand Down Expand Up @@ -222,6 +222,11 @@ export const projectMachine = createMachine(
target: 'Loading mosaic',
actions: ['setCurrentMosaic', 'clearCurrentPrediction'],
},

'Apply timeframe': {
target: 'Applying timeframe',
actions: 'setCurrentTimeframe',
},
},
},

Expand Down Expand Up @@ -728,6 +733,21 @@ export const projectMachine = createMachine(
},
},
},

'Applying timeframe': {
entry: 'enterApplyTimeframe',

on: {
'Timeframe was applied': {
target: 'Prediction ready',
actions: 'hideGlobalLoading',
},
},

invoke: {
src: 'applyTimeframe',
},
},
},
},
{
Expand Down
Loading

0 comments on commit 70933dd

Please sign in to comment.