From 4492ebedc2bb9166bb72011c1322897bd7fed898 Mon Sep 17 00:00:00 2001 From: cdubuisson Date: Sat, 1 Feb 2020 22:19:40 +0100 Subject: [PATCH] :sparkles: : add vue component to render typeahead inputs --- pom.xml | 677 +++++++++--------- .../UIExtensionsControllerAdvice.kt | 3 +- .../components/form-typeahead.vue | 153 ++++ 3 files changed, 502 insertions(+), 331 deletions(-) create mode 100644 src/main/resources/templates/vue_templates/components/form-typeahead.vue diff --git a/pom.xml b/pom.xml index 579961a7f..ff68a1856 100644 --- a/pom.xml +++ b/pom.xml @@ -1,259 +1,276 @@ - 4.0.0 - - - org.springframework.boot - spring-boot-starter-parent - 2.2.4.RELEASE - - - - io.codeka - gaia - 1.3.0-SNAPSHOT - jar - - gaia - gaia runs yours terraform modules - https://github.com/gaia-app/gaia - 2019 - - - - Mozilla Public License Version 2.0 - http://mozilla.org/MPL/2.0/ - - - - - https://github.com/gaia-app/gaia - - - github - https://github.com/gaia-app/gaia/issues - - - travis-ci - https://travis-ci.com/gaia-app/gaia - - - - 4.8-1 - 11 - 2.27 - 5.5.2 - 1.3.61 - 1.12.5 - - gaia-app:gaia - gaia-app - https://sonarcloud.io/ - - - - - - - org.jetbrains.kotlin - kotlin-stdlib-jdk8 - ${kotlin.version} - - - org.jetbrains.kotlin - kotlin-reflect - ${kotlin.version} - - - - org.springframework.boot - spring-boot-starter-data-mongodb - - - org.springframework.boot - spring-boot-starter-web - - - org.springframework.boot - spring-boot-starter-thymeleaf - - - - org.springframework.boot - spring-boot-starter-test - test - - - - org.testcontainers - testcontainers - ${testcontainers.version} - test - - - org.testcontainers - junit-jupiter - ${testcontainers.version} - test - - - - org.webjars - bootstrap - 4.4.1 - - - org.webjars - vue - 2.6.11 - - - org.webjars - font-awesome - 5.12.0 - - - org.webjars.npm - bootstrap-vue - 2.1.0 - - - * - * - - - - - org.webjars.npm - marked - 0.7.0 - - - - org.springframework.boot - spring-boot-devtools - - - - com.spotify - docker-client - 8.16.0 - - - org.glassfish.jersey.inject - jersey-hk2 - ${jersey.version} - - - - org.springframework.boot - spring-boot-starter-security - - - org.springframework.security - spring-security-ldap - - - org.thymeleaf.extras - thymeleaf-extras-springsecurity5 - - - org.springframework.security - spring-security-test - - - - com.github.spullara.mustache.java - compiler - 0.9.6 - - - - - org.webjars.bower - messenger - 1.5.0 - - - * - * - - - - - - org.webjars.npm - vue-multiselect - 2.1.6 - - - - org.springframework.boot - spring-boot-starter-actuator - - - - - com.fasterxml.jackson.module - jackson-module-kotlin - ${jackson.version} - - - - - org.springframework.security - spring-security-oauth2-client - - - - - org.antlr - antlr4-runtime - ${antlr4.version} - - - - - org.seleniumhq.selenium - selenium-java - 3.141.59 - test - - - - io.percy - percy-java-selenium - 0.1.3 - test - - - - - - - - - com.google.guava - guava - 25.0-jre - - - - - - - - - org.jacoco - jacoco-maven-plugin - 0.8.5 - - - - - - + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> + 4.0.0 + + + org.springframework.boot + spring-boot-starter-parent + 2.2.4.RELEASE + + + + io.codeka + gaia + 1.3.0-SNAPSHOT + jar + + gaia + gaia runs yours terraform modules + https://github.com/gaia-app/gaia + 2019 + + + + Mozilla Public License Version 2.0 + http://mozilla.org/MPL/2.0/ + + + + + https://github.com/gaia-app/gaia + + + github + https://github.com/gaia-app/gaia/issues + + + travis-ci + https://travis-ci.com/gaia-app/gaia + + + + 4.8-1 + 11 + 2.27 + 5.5.2 + 1.3.61 + 1.12.5 + + gaia-app:gaia + gaia-app + https://sonarcloud.io/ + + + + + + + org.jetbrains.kotlin + kotlin-stdlib-jdk8 + ${kotlin.version} + + + org.jetbrains.kotlin + kotlin-reflect + ${kotlin.version} + + + + org.springframework.boot + spring-boot-starter-data-mongodb + + + org.springframework.boot + spring-boot-starter-web + + + org.springframework.boot + spring-boot-starter-thymeleaf + + + + org.springframework.boot + spring-boot-starter-test + test + + + + org.testcontainers + testcontainers + ${testcontainers.version} + test + + + org.testcontainers + junit-jupiter + ${testcontainers.version} + test + + + + org.webjars + bootstrap + 4.4.1 + + + org.webjars + vue + 2.6.11 + + + org.webjars + font-awesome + 5.12.0 + + + org.webjars.npm + bootstrap-vue + 2.1.0 + + + * + * + + + + + org.webjars.npm + marked + 0.7.0 + + + + org.springframework.boot + spring-boot-devtools + + + + com.spotify + docker-client + 8.16.0 + + + org.glassfish.jersey.inject + jersey-hk2 + ${jersey.version} + + + + org.springframework.boot + spring-boot-starter-security + + + org.springframework.security + spring-security-ldap + + + org.thymeleaf.extras + thymeleaf-extras-springsecurity5 + + + org.springframework.security + spring-security-test + + + + com.github.spullara.mustache.java + compiler + 0.9.6 + + + + + org.webjars.bower + messenger + 1.5.0 + + + * + * + + + + + + org.webjars.npm + vue-multiselect + 2.1.6 + + + + org.springframework.boot + spring-boot-starter-actuator + + + + + com.fasterxml.jackson.module + jackson-module-kotlin + ${jackson.version} + + + + + org.springframework.security + spring-security-oauth2-client + + + + + org.antlr + antlr4-runtime + ${antlr4.version} + + + + + org.seleniumhq.selenium + selenium-java + 3.141.59 + test + + + + io.percy + percy-java-selenium + 0.1.3 + test + + + + + org.webjars.npm + corejs-typeahead + 1.2.1 + + + + org.webjars.npm + jquery + + + + + + + + + + + com.google.guava + guava + 25.0-jre + + + + + + + + + org.jacoco + jacoco-maven-plugin + 0.8.5 + + + + + + org.jetbrains.kotlin kotlin-maven-plugin ${kotlin.version} @@ -267,16 +284,16 @@ compile - process-sources - - compile - - - - test-compile - process-test-sources - - test-compile + process-sources + + compile + + + + test-compile + process-test-sources + + test-compile @@ -291,71 +308,71 @@ org.springframework.boot - spring-boot-maven-plugin - - - - - - build-info - - - - - - org.apache.maven.plugins - maven-surefire-plugin - - - **/*Test.java - **/*IT.java - - - - - - - - pl.project13.maven - git-commit-id-plugin - - - - org.antlr - antlr4-maven-plugin - ${antlr4.version} - - - - antlr4 - - - true - false - - - - - - - org.pitest - pitest-maven - 1.4.11 - - - org.pitest - pitest-junit5-plugin - 0.12 - - - - *IT - - kotlin.jvm.internal - - - - - + spring-boot-maven-plugin + + + + + + build-info + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + **/*Test.java + **/*IT.java + + + + + + + + pl.project13.maven + git-commit-id-plugin + + + + org.antlr + antlr4-maven-plugin + ${antlr4.version} + + + + antlr4 + + + true + false + + + + + + + org.pitest + pitest-maven + 1.4.11 + + + org.pitest + pitest-junit5-plugin + 0.12 + + + + *IT + + kotlin.jvm.internal + + + + + diff --git a/src/main/java/io/codeka/gaia/dashboard/controller/UIExtensionsControllerAdvice.kt b/src/main/java/io/codeka/gaia/dashboard/controller/UIExtensionsControllerAdvice.kt index ddc768848..1337bd735 100644 --- a/src/main/java/io/codeka/gaia/dashboard/controller/UIExtensionsControllerAdvice.kt +++ b/src/main/java/io/codeka/gaia/dashboard/controller/UIExtensionsControllerAdvice.kt @@ -46,7 +46,8 @@ open class UIExtensionsConfig(){ "classpath*:/**/vue/**/vue.min.js", "classpath*:/**/bootstrap-vue/**/bootstrap-vue.min.js", "classpath*:/**/marked/**/marked.min.js", - "classpath*:/**/vue-multiselect/**/vue-multiselect.min.js" + "classpath*:/**/vue-multiselect/**/vue-multiselect.min.js", + "classpath*:/**/corejs-typeahead/**/typeahead.bundle.min.js" ) } } diff --git a/src/main/resources/templates/vue_templates/components/form-typeahead.vue b/src/main/resources/templates/vue_templates/components/form-typeahead.vue new file mode 100644 index 000000000..579d9a05b --- /dev/null +++ b/src/main/resources/templates/vue_templates/components/form-typeahead.vue @@ -0,0 +1,153 @@ + + + + +