static void ensureInjected() { if (isVueLibInjected()) { return; } HTMLScriptElement scriptElement = (HTMLScriptElement) DomGlobal.document.createElement("script"); scriptElement.text = VUE_DEV_RUNTIME; DomGlobal.document.body.appendChild(scriptElement); }
static void ensureInjected() { if (isVueLibInjected()) { return; } HTMLScriptElement scriptElement = (HTMLScriptElement) DomGlobal.document.createElement("script"); scriptElement.text = VUE_RUNTIME; DomGlobal.document.body.appendChild(scriptElement); }
static void ensureInjected() { if (isCustomElementInjected()) { return; } HTMLScriptElement scriptElement = (HTMLScriptElement) DomGlobal.document.createElement("script"); scriptElement.text = VUE_CUSTOM_ELEMENT; DomGlobal.document.body.appendChild(scriptElement); }
private void createHiddenInput() { hiddenFileInput = input("file") .style("visibility: hidden; position: absolute; top: 0px; left: 0px; height: 0px; width: 0px;").asElement(); DomGlobal.document.body.appendChild(hiddenFileInput); }
private void createHiddenInput() { hiddenFileInput = input("file") .style("visibility: hidden; position: absolute; top: 0px; left: 0px; height: 0px; width: 0px;").asElement(); DomGlobal.document.body.appendChild(hiddenFileInput); }
public Layout show(ColorScheme theme, boolean autoFixLeftPanel) { new Theme(theme).apply(); if (autoFixLeftPanel) { autoFixLeftPanel(); } if (!root.isAttached()) { document.body.appendChild(root.asElement()); } return this; }
public Layout show(ColorScheme theme, boolean autoFixLeftPanel) { new Theme(theme).apply(); if (autoFixLeftPanel) { autoFixLeftPanel(); } if (!root.isAttached()) { document.body.appendChild(root.asElement()); } return this; }
public void addBackdrop() { if (opened_dialogs <= 0) { document.body.appendChild(ModalBackDrop.INSTANCE); DominoElement.of(document.body).style().add(ModalStyles.MODAL_OPEN); } else { Z_INDEX = Z_INDEX + 10; ModalBackDrop.INSTANCE.style.setProperty("z-index", Z_INDEX + ""); asElement().style.setProperty("z-index", (Z_INDEX + 10) + ""); } }
public void addBackdrop() { if (opened_dialogs <= 0) { document.body.appendChild(ModalBackDrop.INSTANCE); DominoElement.of(document.body).style().add(ModalStyles.MODAL_OPEN); } else { Z_INDEX = Z_INDEX + 10; ModalBackDrop.INSTANCE.style.setProperty("z-index", Z_INDEX + ""); asElement().style.setProperty("z-index", (Z_INDEX + 10) + ""); } }
private void showInModal() { if (!PickerStyle.MODAL.equals(this.pickerStyle)) { if (nonNull(popover)) { this.popover.discard(); } if (isNull(modal)) { this.modal = ModalDialog.createPickerModal(getPlaceholder(), this.timePicker.asElement()); DomGlobal.document.body.appendChild(modal.asElement()); asElement().addEventListener(EventType.click.getName(), modalListener); asElement().addEventListener(EventType.keydown.getName(), keyboardModalListener); } } this.pickerStyle = PickerStyle.MODAL; }
private void showInModal() { if (!PickerStyle.MODAL.equals(this.pickerStyle)) { if (nonNull(popover)) { this.popover.discard(); } if (isNull(modal)) { this.modal = ModalDialog.createPickerModal(getPlaceholder(), this.timePicker.asElement()); DomGlobal.document.body.appendChild(modal.asElement()); asElement().addEventListener(EventType.click.getName(), modalListener); asElement().addEventListener(EventType.keydown.getName(), keyboardModalListener); } } this.pickerStyle = PickerStyle.MODAL; }
public void open() { if (hasActions()) { if (!document.body.contains(element.asElement())) { document.body.appendChild(element.asElement()); } position.position(element.asElement(), targetElement); if (searchable) { searchBox.asElement().focus(); clearSearch(); } } }
public void open() { if (hasActions()) { if (!document.body.contains(element.asElement())) { document.body.appendChild(element.asElement()); } position.position(element.asElement(), targetElement); if (searchable) { searchBox.asElement().focus(); clearSearch(); } } }
private void open(HTMLElement target) { if (visible) { close(); } else { document.body.appendChild(element.asElement()); element.style().remove("fade", "in"); element.style().add("fade", "in"); popupPosition.position(element.asElement(), target); position(popupPosition); visible = true; if(closeOnEscp) { KeyboardEvents.listenOn(document.body) .onEscape(closeListener); } } }
private void open(HTMLElement target) { if (visible) { close(); } else { document.body.appendChild(element.asElement()); element.style().remove("fade", "in"); element.style().add("fade", "in"); popupPosition.position(element.asElement(), target); position(popupPosition); visible = true; if(closeOnEscp) { KeyboardEvents.listenOn(document.body) .onEscape(closeListener); } } }
public Notification show() { position.onBeforeAttach(asElement()); DomGlobal.document.body.appendChild(asElement()); position.onNewElement(asElement()); Animation.create(asElement()) .transition(inTransition) .callback(e -> Animation.create(asElement()) .delay(duration) .transition(outTransition) .callback(e2 -> asElement().remove()) .animate()) .animate(); return this; }
public Notification show() { position.onBeforeAttach(asElement()); DomGlobal.document.body.appendChild(asElement()); position.onNewElement(asElement()); Animation.create(asElement()) .transition(inTransition) .callback(e -> Animation.create(asElement()) .delay(duration) .transition(outTransition) .callback(e2 -> asElement().remove()) .animate()) .animate(); return this; }
public Tooltip(HTMLElement targetElement, Node content) { this.targetElement = targetElement; element.appendChild(arrowElement); element.appendChild(innerElement); innerElement.appendChild(content); element.style().add(popupPosition.getDirectionClass()); targetElement.addEventListener(EventType.mouseenter.getName(), evt -> { evt.stopPropagation(); document.body.appendChild(element.asElement()); element.style().remove("fade", "in"); element.style().add("fade", "in"); popupPosition.position(element.asElement(), targetElement); position(popupPosition); DominoElement.of(targetElement).onDetached(mutationRecord -> hide()); }); targetElement.addEventListener(EventType.mouseleave.getName(), evt1 -> element.remove()); init(this); }
public Tooltip(HTMLElement targetElement, Node content) { this.targetElement = targetElement; element.appendChild(arrowElement); element.appendChild(innerElement); innerElement.appendChild(content); element.style().add(popupPosition.getDirectionClass()); targetElement.addEventListener(EventType.mouseenter.getName(), evt -> { evt.stopPropagation(); document.body.appendChild(element.asElement()); element.style().remove("fade", "in"); element.style().add("fade", "in"); popupPosition.position(element.asElement(), targetElement); position(popupPosition); DominoElement.of(targetElement).onDetached(mutationRecord -> hide()); }); targetElement.addEventListener(EventType.mouseleave.getName(), evt1 -> element.remove()); init(this); }
public static void init() { GWT.setUncaughtExceptionHandler(throwable -> LOGGER.error("Uncaught Exception", throwable)); ClientRouter clientRouter = new ClientRouter(new ClientEventFactory()); ServerRouter serverRouter = new ServerRouter(new GwtRequestAsyncSender(new ServerEventFactory())); RequestEventProcessor requestEventProcessor = new RequestEventProcessor(); SimpleEventsBus eventBus = new SimpleEventsBus(requestEventProcessor); SlotRegistry.registerSlot("root", content -> { DomGlobal.document.body.appendChild(Js.<HTMLElement>cast(content.get())); }); ClientApp.ClientAppBuilder .clientRouter(clientRouter) .serverRouter(serverRouter) .eventsBus(eventBus) .requestRepository(new InMemoryCommandsRepository()) .presentersRepository(new InMemoryPresentersRepository()) .viewsRepository(new InMemoryViewRepository()) .eventsListenersRepository(new InMemoryDominoEventsListenerRepository()) .requestSendersRepository(new InMemoryRequestRestSendersRepository()) .history(new StateHistory()) .asyncRunner(new GwtAsyncRunner()) .mainExtensionPoint(new CoreMainExtensionPoint()) .dominoOptions(new DefaultDominoOptions()) .build(); } }