diff --git a/src/Main.elm b/src/Main.elm index 8574e617cdb71e7e5fbb5a58adaf492be7a5e0e5..279c58b8b9cdd6dbea4da147190b26c9205636ea 100644 --- a/src/Main.elm +++ b/src/Main.elm @@ -95,7 +95,7 @@ update msg ( global, local ) = loadingfdg = { fdg | loading = True } in - ( ( { global | view = newView }, local ) + ( ( { global | view = newView }, { local | forcedirectedgraph = loadingfdg } ) , ForceDirectedGraphView.calculateModel global.data loadingfdg |> Cmd.map ForceDirectedGraphView.propagate ) diff --git a/src/Views/ForceDirectedGraph.elm b/src/Views/ForceDirectedGraph.elm index 2e4fef34df79d7db0ccaaa7c98a59666366340da..28180e7ce17c8c69511ec16f20b431d0a35b3b16 100644 --- a/src/Views/ForceDirectedGraph.elm +++ b/src/Views/ForceDirectedGraph.elm @@ -404,14 +404,11 @@ postInit data local = list = Force.computeSimulation (Force.simulation forces) <| List.map .label <| Graph.nodes graph in - Task.succeed (Ok { firstInit | loading = True }) - |> Task.andThen - (\_ -> - Task.succeed - (Ok - (Local.Model (updateGraphWithList graph list) (Force.simulation forces) 0 False "" 0 0) - ) - ) + Task.succeed + (Ok + --(Local.Model (updateGraphWithList graph list) (Force.simulation forces) 0 True "" 0 0) + { local | graph = updateGraphWithList graph list, simulation = Force.simulation forces, loading = True } + ) isSchengen : Graph.Node Local.Entity -> List Entry -> Bool