Skip to content

Commit

Permalink
deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
vegegoku committed Dec 11, 2023
1 parent 88087b4 commit a3ffd17
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ public void onModuleLoad() {
DominoRestConfig.initDefaults();
DominoGWT.init(DominoViewOptions.getInstance());
DominoThemeManager.INSTANCE.applyUserThemes();

ClientApp.make().run();
LOGGER.info("dominokit-site Application frontend have been initialized.");
if (ClientApp.make().getHistory().currentToken().isEmpty()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import org.dominokit.domino.api.client.extension.DominoEvents;
import org.dominokit.domino.history.HistoryToken;
import org.dominokit.domino.history.StateToken;
import org.dominokit.pages.client.presenters.samples.SiteEvents;
import org.dominokit.pages.client.views.PagesView;
import org.dominokit.pages.shared.events.ContentState;

Expand Down Expand Up @@ -35,7 +36,7 @@ public void loadContent(HistoryToken token, PagesView view) {
view.replaceContent(content, "dui-content-container");
view.enhancePadding();
view.registerSlots();
DominoEvents.fire(ContentState.class, new ContentState(true));
SiteEvents.fireContentEvent();
ClientApp.make().getHistory().fireState(StateToken.of(ClientApp.make().getHistory().currentToken()));
});
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package org.dominokit.pages.client.presenters;

import dominoaggregate.shaded.com.apache.commons.lang3.concurrent.LazyInitializer;
import elemental2.dom.DomGlobal;
import org.dominokit.domino.api.client.annotations.presenter.ListenTo;
import org.dominokit.domino.api.client.annotations.presenter.OnReveal;
Expand All @@ -13,6 +14,7 @@
@Slot("dui-demo-sample-slot")
public abstract class SampleProxy extends ViewablePresenter<SampleView> implements SampleView.SampleUiHandlers {


@PostConstruct
public void onPostConstruct() {
DomGlobal.console.info(">Activating sample view.");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import elemental2.dom.DomGlobal;
import org.dominokit.domino.api.client.extension.DominoEvents;
import org.dominokit.domino.history.HistoryToken;
import org.dominokit.pages.client.presenters.samples.SiteEvents;
import org.dominokit.pages.client.views.PagesView;
import org.dominokit.pages.shared.events.ContentState;

Expand All @@ -25,8 +26,7 @@ public void loadContent(HistoryToken token, PagesView view) {
view.replaceContent(content, container);
view.enhancePadding();
view.registerSlots();
DomGlobal.console.info("Firing content ready event :");
DominoEvents.fire(ContentState.class, new ContentState(true));
SiteEvents.fireContentEvent();

});
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package org.dominokit.pages.client.presenters.samples;

import elemental2.dom.DomGlobal;
import org.dominokit.domino.api.client.extension.DominoEvents;
import org.dominokit.pages.shared.events.ContentState;

public class SiteEvents {
public static void fireContentEvent(){
DomGlobal.console.info("= [:] FIRING CONTENT EVENT [:] =");
DominoEvents.fire(ContentState.class, new ContentState(true));
}
}

0 comments on commit a3ffd17

Please sign in to comment.