This commit is contained in:
Sebastian Seedorf
2019-01-10 13:08:06 +01:00
commit 096f2f1c4b
59 changed files with 44318 additions and 0 deletions

3
.gitignore vendored Normal file
View File

@@ -0,0 +1,3 @@
node_modules/
routes/*.js
routes/*.js.map

52
.idea/codeStyles/Project.xml generated Normal file
View File

@@ -0,0 +1,52 @@
<component name="ProjectCodeStyleConfiguration">
<code_scheme name="Project" version="173">
<DBN-PSQL>
<case-options enabled="false">
<option name="KEYWORD_CASE" value="lower" />
<option name="FUNCTION_CASE" value="lower" />
<option name="PARAMETER_CASE" value="lower" />
<option name="DATATYPE_CASE" value="lower" />
<option name="OBJECT_CASE" value="preserve" />
</case-options>
<formatting-settings enabled="false" />
</DBN-PSQL>
<DBN-SQL>
<case-options enabled="false">
<option name="KEYWORD_CASE" value="lower" />
<option name="FUNCTION_CASE" value="lower" />
<option name="PARAMETER_CASE" value="lower" />
<option name="DATATYPE_CASE" value="lower" />
<option name="OBJECT_CASE" value="preserve" />
</case-options>
<formatting-settings enabled="false">
<option name="STATEMENT_SPACING" value="one_line" />
<option name="CLAUSE_CHOP_DOWN" value="chop_down_if_statement_long" />
<option name="ITERATION_ELEMENTS_WRAPPING" value="chop_down_if_not_single" />
</formatting-settings>
</DBN-SQL>
<TypeScriptCodeStyleSettings>
<option name="FORCE_SEMICOLON_STYLE" value="true" />
</TypeScriptCodeStyleSettings>
<codeStyleSettings language="Jade">
<indentOptions>
<option name="INDENT_SIZE" value="2" />
<option name="TAB_SIZE" value="2" />
</indentOptions>
</codeStyleSettings>
<codeStyleSettings language="JavaScript">
<indentOptions>
<option name="INDENT_SIZE" value="2" />
<option name="CONTINUATION_INDENT_SIZE" value="2" />
<option name="TAB_SIZE" value="2" />
</indentOptions>
</codeStyleSettings>
<codeStyleSettings language="TypeScript">
<option name="RIGHT_MARGIN" value="120" />
<indentOptions>
<option name="INDENT_SIZE" value="2" />
<option name="CONTINUATION_INDENT_SIZE" value="2" />
<option name="TAB_SIZE" value="2" />
</indentOptions>
</codeStyleSettings>
</code_scheme>
</component>

6
.idea/codeStyles/codeStyleConfig.xml generated Normal file
View File

@@ -0,0 +1,6 @@
<component name="ProjectCodeStyleConfiguration">
<state>
<option name="USE_PER_PROJECT_SETTINGS" value="true" />
<option name="PREFERRED_PROJECT_CODE_STYLE" value="Default" />
</state>
</component>

453
.idea/dbnavigator.xml generated Normal file
View File

@@ -0,0 +1,453 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="DBNavigator.Project.DataEditorManager">
<record-view-column-sorting-type value="BY_INDEX" />
<value-preview-text-wrapping value="true" />
<value-preview-pinned value="false" />
</component>
<component name="DBNavigator.Project.DataExportManager">
<export-instructions>
<create-header value="true" />
<quote-values-containing-separator value="true" />
<quote-all-values value="false" />
<value-separator value="" />
<file-name value="" />
<file-location value="" />
<scope value="GLOBAL" />
<destination value="FILE" />
<format value="EXCEL" />
<charset value="UTF-8" />
</export-instructions>
</component>
<component name="DBNavigator.Project.DatabaseBrowserManager">
<autoscroll-to-editor value="false" />
<autoscroll-from-editor value="true" />
<show-object-properties value="true" />
<loaded-nodes />
</component>
<component name="DBNavigator.Project.EditorStateManager">
<last-used-providers />
</component>
<component name="DBNavigator.Project.MethodExecutionManager">
<method-browser />
<execution-history>
<group-entries value="true" />
<execution-inputs />
</execution-history>
<argument-values-cache />
</component>
<component name="DBNavigator.Project.ObjectDependencyManager">
<last-used-dependency-type value="INCOMING" />
</component>
<component name="DBNavigator.Project.ObjectQuickFilterManager">
<last-used-operator value="EQUAL" />
<filters />
</component>
<component name="DBNavigator.Project.ScriptExecutionManager" clear-outputs="true">
<recently-used-interfaces />
</component>
<component name="DBNavigator.Project.Settings">
<connections />
<browser-settings>
<general>
<display-mode value="TABBED" />
<navigation-history-size value="100" />
<show-object-details value="false" />
</general>
<filters>
<object-type-filter>
<object-type name="SCHEMA" enabled="true" />
<object-type name="USER" enabled="true" />
<object-type name="ROLE" enabled="true" />
<object-type name="PRIVILEGE" enabled="true" />
<object-type name="CHARSET" enabled="true" />
<object-type name="TABLE" enabled="true" />
<object-type name="VIEW" enabled="true" />
<object-type name="MATERIALIZED_VIEW" enabled="true" />
<object-type name="NESTED_TABLE" enabled="true" />
<object-type name="COLUMN" enabled="true" />
<object-type name="INDEX" enabled="true" />
<object-type name="CONSTRAINT" enabled="true" />
<object-type name="DATASET_TRIGGER" enabled="true" />
<object-type name="DATABASE_TRIGGER" enabled="true" />
<object-type name="SYNONYM" enabled="true" />
<object-type name="SEQUENCE" enabled="true" />
<object-type name="PROCEDURE" enabled="true" />
<object-type name="FUNCTION" enabled="true" />
<object-type name="PACKAGE" enabled="true" />
<object-type name="TYPE" enabled="true" />
<object-type name="TYPE_ATTRIBUTE" enabled="true" />
<object-type name="ARGUMENT" enabled="true" />
<object-type name="DIMENSION" enabled="true" />
<object-type name="CLUSTER" enabled="true" />
<object-type name="DBLINK" enabled="true" />
</object-type-filter>
</filters>
<sorting>
<object-type name="COLUMN" sorting-type="NAME" />
<object-type name="FUNCTION" sorting-type="NAME" />
<object-type name="PROCEDURE" sorting-type="NAME" />
<object-type name="ARGUMENT" sorting-type="POSITION" />
</sorting>
<default-editors>
<object-type name="VIEW" editor-type="SELECTION" />
<object-type name="PACKAGE" editor-type="SELECTION" />
<object-type name="TYPE" editor-type="SELECTION" />
</default-editors>
</browser-settings>
<navigation-settings>
<lookup-filters>
<lookup-objects>
<object-type name="SCHEMA" enabled="true" />
<object-type name="USER" enabled="false" />
<object-type name="ROLE" enabled="false" />
<object-type name="PRIVILEGE" enabled="false" />
<object-type name="CHARSET" enabled="false" />
<object-type name="TABLE" enabled="true" />
<object-type name="VIEW" enabled="true" />
<object-type name="MATERIALIZED VIEW" enabled="true" />
<object-type name="NESTED TABLE" enabled="false" />
<object-type name="COLUMN" enabled="false" />
<object-type name="INDEX" enabled="true" />
<object-type name="CONSTRAINT" enabled="true" />
<object-type name="DATASET TRIGGER" enabled="true" />
<object-type name="DATABASE TRIGGER" enabled="true" />
<object-type name="SYNONYM" enabled="false" />
<object-type name="SEQUENCE" enabled="true" />
<object-type name="PROCEDURE" enabled="true" />
<object-type name="FUNCTION" enabled="true" />
<object-type name="PACKAGE" enabled="true" />
<object-type name="TYPE" enabled="true" />
<object-type name="TYPE ATTRIBUTE" enabled="false" />
<object-type name="ARGUMENT" enabled="false" />
<object-type name="DIMENSION" enabled="false" />
<object-type name="CLUSTER" enabled="false" />
<object-type name="DBLINK" enabled="true" />
</lookup-objects>
<force-database-load value="false" />
<prompt-connection-selection value="true" />
<prompt-schema-selection value="true" />
</lookup-filters>
</navigation-settings>
<dataset-grid-settings>
<general>
<enable-zooming value="true" />
<enable-column-tooltip value="true" />
</general>
<sorting>
<nulls-first value="true" />
<max-sorting-columns value="4" />
</sorting>
<tracking-columns>
<columnNames value="" />
<visible value="true" />
<editable value="false" />
</tracking-columns>
</dataset-grid-settings>
<dataset-editor-settings>
<text-editor-popup>
<active value="false" />
<active-if-empty value="false" />
<data-length-threshold value="100" />
<popup-delay value="1000" />
</text-editor-popup>
<values-list-popup>
<show-popup-button value="true" />
<element-count-threshold value="1000" />
<data-length-threshold value="250" />
</values-list-popup>
<general>
<fetch-block-size value="100" />
<fetch-timeout value="30" />
<trim-whitespaces value="true" />
<convert-empty-strings-to-null value="true" />
<select-content-on-cell-edit value="true" />
<large-value-preview-active value="true" />
</general>
<filters>
<prompt-filter-dialog value="true" />
<default-filter-type value="BASIC" />
</filters>
<qualified-text-editor text-length-threshold="300">
<content-types>
<content-type name="Text" enabled="true" />
<content-type name="XML" enabled="true" />
<content-type name="DTD" enabled="true" />
<content-type name="HTML" enabled="true" />
<content-type name="XHTML" enabled="true" />
<content-type name="CSS" enabled="true" />
<content-type name="SQL" enabled="true" />
<content-type name="PL/SQL" enabled="true" />
<content-type name="JavaScript" enabled="true" />
<content-type name="JSP" enabled="true" />
<content-type name="JSPx" enabled="true" />
<content-type name="ASP" enabled="true" />
<content-type name="YAML" enabled="true" />
</content-types>
</qualified-text-editor>
<record-navigation>
<navigation-target value="VIEWER" />
</record-navigation>
</dataset-editor-settings>
<code-editor-settings>
<general>
<show-object-navigation-gutter value="false" />
<show-spec-declaration-navigation-gutter value="true" />
<enable-spellchecking value="true" />
<enable-reference-spellchecking value="false" />
</general>
<confirmations>
<save-changes value="false" />
<revert-changes value="true" />
</confirmations>
</code-editor-settings>
<code-completion-settings>
<filters>
<basic-filter>
<filter-element type="RESERVED_WORD" id="keyword" selected="true" />
<filter-element type="RESERVED_WORD" id="function" selected="true" />
<filter-element type="RESERVED_WORD" id="parameter" selected="true" />
<filter-element type="RESERVED_WORD" id="datatype" selected="true" />
<filter-element type="RESERVED_WORD" id="exception" selected="true" />
<filter-element type="OBJECT" id="schema" selected="true" />
<filter-element type="OBJECT" id="role" selected="true" />
<filter-element type="OBJECT" id="user" selected="true" />
<filter-element type="OBJECT" id="privilege" selected="true" />
<user-schema>
<filter-element type="OBJECT" id="table" selected="true" />
<filter-element type="OBJECT" id="view" selected="true" />
<filter-element type="OBJECT" id="materialized view" selected="true" />
<filter-element type="OBJECT" id="index" selected="true" />
<filter-element type="OBJECT" id="constraint" selected="true" />
<filter-element type="OBJECT" id="trigger" selected="true" />
<filter-element type="OBJECT" id="synonym" selected="false" />
<filter-element type="OBJECT" id="sequence" selected="true" />
<filter-element type="OBJECT" id="procedure" selected="true" />
<filter-element type="OBJECT" id="function" selected="true" />
<filter-element type="OBJECT" id="package" selected="true" />
<filter-element type="OBJECT" id="type" selected="true" />
<filter-element type="OBJECT" id="dimension" selected="true" />
<filter-element type="OBJECT" id="cluster" selected="true" />
<filter-element type="OBJECT" id="dblink" selected="true" />
</user-schema>
<public-schema>
<filter-element type="OBJECT" id="table" selected="false" />
<filter-element type="OBJECT" id="view" selected="false" />
<filter-element type="OBJECT" id="materialized view" selected="false" />
<filter-element type="OBJECT" id="index" selected="false" />
<filter-element type="OBJECT" id="constraint" selected="false" />
<filter-element type="OBJECT" id="trigger" selected="false" />
<filter-element type="OBJECT" id="synonym" selected="false" />
<filter-element type="OBJECT" id="sequence" selected="false" />
<filter-element type="OBJECT" id="procedure" selected="false" />
<filter-element type="OBJECT" id="function" selected="false" />
<filter-element type="OBJECT" id="package" selected="false" />
<filter-element type="OBJECT" id="type" selected="false" />
<filter-element type="OBJECT" id="dimension" selected="false" />
<filter-element type="OBJECT" id="cluster" selected="false" />
<filter-element type="OBJECT" id="dblink" selected="false" />
</public-schema>
<any-schema>
<filter-element type="OBJECT" id="table" selected="true" />
<filter-element type="OBJECT" id="view" selected="true" />
<filter-element type="OBJECT" id="materialized view" selected="true" />
<filter-element type="OBJECT" id="index" selected="true" />
<filter-element type="OBJECT" id="constraint" selected="true" />
<filter-element type="OBJECT" id="trigger" selected="true" />
<filter-element type="OBJECT" id="synonym" selected="true" />
<filter-element type="OBJECT" id="sequence" selected="true" />
<filter-element type="OBJECT" id="procedure" selected="true" />
<filter-element type="OBJECT" id="function" selected="true" />
<filter-element type="OBJECT" id="package" selected="true" />
<filter-element type="OBJECT" id="type" selected="true" />
<filter-element type="OBJECT" id="dimension" selected="true" />
<filter-element type="OBJECT" id="cluster" selected="true" />
<filter-element type="OBJECT" id="dblink" selected="true" />
</any-schema>
</basic-filter>
<extended-filter>
<filter-element type="RESERVED_WORD" id="keyword" selected="true" />
<filter-element type="RESERVED_WORD" id="function" selected="true" />
<filter-element type="RESERVED_WORD" id="parameter" selected="true" />
<filter-element type="RESERVED_WORD" id="datatype" selected="true" />
<filter-element type="RESERVED_WORD" id="exception" selected="true" />
<filter-element type="OBJECT" id="schema" selected="true" />
<filter-element type="OBJECT" id="user" selected="true" />
<filter-element type="OBJECT" id="role" selected="true" />
<filter-element type="OBJECT" id="privilege" selected="true" />
<user-schema>
<filter-element type="OBJECT" id="table" selected="true" />
<filter-element type="OBJECT" id="view" selected="true" />
<filter-element type="OBJECT" id="materialized view" selected="true" />
<filter-element type="OBJECT" id="index" selected="true" />
<filter-element type="OBJECT" id="constraint" selected="true" />
<filter-element type="OBJECT" id="trigger" selected="true" />
<filter-element type="OBJECT" id="synonym" selected="true" />
<filter-element type="OBJECT" id="sequence" selected="true" />
<filter-element type="OBJECT" id="procedure" selected="true" />
<filter-element type="OBJECT" id="function" selected="true" />
<filter-element type="OBJECT" id="package" selected="true" />
<filter-element type="OBJECT" id="type" selected="true" />
<filter-element type="OBJECT" id="dimension" selected="true" />
<filter-element type="OBJECT" id="cluster" selected="true" />
<filter-element type="OBJECT" id="dblink" selected="true" />
</user-schema>
<public-schema>
<filter-element type="OBJECT" id="table" selected="true" />
<filter-element type="OBJECT" id="view" selected="true" />
<filter-element type="OBJECT" id="materialized view" selected="true" />
<filter-element type="OBJECT" id="index" selected="true" />
<filter-element type="OBJECT" id="constraint" selected="true" />
<filter-element type="OBJECT" id="trigger" selected="true" />
<filter-element type="OBJECT" id="synonym" selected="true" />
<filter-element type="OBJECT" id="sequence" selected="true" />
<filter-element type="OBJECT" id="procedure" selected="true" />
<filter-element type="OBJECT" id="function" selected="true" />
<filter-element type="OBJECT" id="package" selected="true" />
<filter-element type="OBJECT" id="type" selected="true" />
<filter-element type="OBJECT" id="dimension" selected="true" />
<filter-element type="OBJECT" id="cluster" selected="true" />
<filter-element type="OBJECT" id="dblink" selected="true" />
</public-schema>
<any-schema>
<filter-element type="OBJECT" id="table" selected="true" />
<filter-element type="OBJECT" id="view" selected="true" />
<filter-element type="OBJECT" id="materialized view" selected="true" />
<filter-element type="OBJECT" id="index" selected="true" />
<filter-element type="OBJECT" id="constraint" selected="true" />
<filter-element type="OBJECT" id="trigger" selected="true" />
<filter-element type="OBJECT" id="synonym" selected="true" />
<filter-element type="OBJECT" id="sequence" selected="true" />
<filter-element type="OBJECT" id="procedure" selected="true" />
<filter-element type="OBJECT" id="function" selected="true" />
<filter-element type="OBJECT" id="package" selected="true" />
<filter-element type="OBJECT" id="type" selected="true" />
<filter-element type="OBJECT" id="dimension" selected="true" />
<filter-element type="OBJECT" id="cluster" selected="true" />
<filter-element type="OBJECT" id="dblink" selected="true" />
</any-schema>
</extended-filter>
</filters>
<sorting enabled="true">
<sorting-element type="RESERVED_WORD" id="keyword" />
<sorting-element type="RESERVED_WORD" id="datatype" />
<sorting-element type="OBJECT" id="column" />
<sorting-element type="OBJECT" id="table" />
<sorting-element type="OBJECT" id="view" />
<sorting-element type="OBJECT" id="materialized view" />
<sorting-element type="OBJECT" id="index" />
<sorting-element type="OBJECT" id="constraint" />
<sorting-element type="OBJECT" id="trigger" />
<sorting-element type="OBJECT" id="synonym" />
<sorting-element type="OBJECT" id="sequence" />
<sorting-element type="OBJECT" id="procedure" />
<sorting-element type="OBJECT" id="function" />
<sorting-element type="OBJECT" id="package" />
<sorting-element type="OBJECT" id="type" />
<sorting-element type="OBJECT" id="dimension" />
<sorting-element type="OBJECT" id="cluster" />
<sorting-element type="OBJECT" id="dblink" />
<sorting-element type="OBJECT" id="schema" />
<sorting-element type="OBJECT" id="role" />
<sorting-element type="OBJECT" id="user" />
<sorting-element type="RESERVED_WORD" id="function" />
<sorting-element type="RESERVED_WORD" id="parameter" />
</sorting>
<format>
<enforce-code-style-case value="true" />
</format>
</code-completion-settings>
<execution-engine-settings>
<statement-execution>
<fetch-block-size value="100" />
<execution-timeout value="20" />
<debug-execution-timeout value="600" />
<focus-result value="false" />
<prompt-execution value="false" />
</statement-execution>
<script-execution>
<command-line-interfaces />
<execution-timeout value="300" />
</script-execution>
<method-execution>
<execution-timeout value="30" />
<debug-execution-timeout value="600" />
<parameter-history-size value="10" />
</method-execution>
</execution-engine-settings>
<operation-settings>
<transactions>
<uncommitted-changes>
<on-project-close value="ASK" />
<on-disconnect value="ASK" />
<on-autocommit-toggle value="ASK" />
</uncommitted-changes>
<multiple-uncommitted-changes>
<on-commit value="ASK" />
<on-rollback value="ASK" />
</multiple-uncommitted-changes>
</transactions>
<session-browser>
<disconnect-session value="ASK" />
<kill-session value="ASK" />
<reload-on-filter-change value="false" />
</session-browser>
<compiler>
<compile-type value="KEEP" />
<compile-dependencies value="ASK" />
<always-show-controls value="false" />
</compiler>
<debugger>
<debugger-type value="JDBC" />
<use-generic-runners value="true" />
</debugger>
</operation-settings>
<ddl-file-settings>
<extensions>
<mapping file-type-id="VIEW" extensions="vw" />
<mapping file-type-id="TRIGGER" extensions="trg" />
<mapping file-type-id="PROCEDURE" extensions="prc" />
<mapping file-type-id="FUNCTION" extensions="fnc" />
<mapping file-type-id="PACKAGE" extensions="pkg" />
<mapping file-type-id="PACKAGE_SPEC" extensions="pks" />
<mapping file-type-id="PACKAGE_BODY" extensions="pkb" />
<mapping file-type-id="TYPE" extensions="tpe" />
<mapping file-type-id="TYPE_SPEC" extensions="tps" />
<mapping file-type-id="TYPE_BODY" extensions="tpb" />
</extensions>
<general>
<lookup-ddl-files value="true" />
<create-ddl-files value="false" />
<synchronize-ddl-files value="true" />
<use-qualified-names value="false" />
<make-scripts-rerunnable value="true" />
</general>
</ddl-file-settings>
<general-settings>
<regional-settings>
<date-format value="MEDIUM" />
<number-format value="UNGROUPED" />
<locale value="SYSTEM_DEFAULT" />
<use-custom-formats value="false" />
</regional-settings>
<environment>
<environment-types>
<environment-type id="development" name="Development" description="Development environment" color="-2430209/-12296320" readonly-code="false" readonly-data="false" />
<environment-type id="integration" name="Integration" description="Integration environment" color="-2621494/-12163514" readonly-code="true" readonly-data="false" />
<environment-type id="production" name="Production" description="Productive environment" color="-11574/-10271420" readonly-code="true" readonly-data="true" />
<environment-type id="other" name="Other" description="" color="-1576/-10724543" readonly-code="false" readonly-data="false" />
</environment-types>
<visibility-settings>
<connection-tabs value="true" />
<dialog-headers value="true" />
<object-editor-tabs value="true" />
<script-editor-tabs value="false" />
<execution-result-tabs value="true" />
</visibility-settings>
</environment>
</general-settings>
</component>
<component name="DBNavigator.Project.StatementExecutionManager">
<execution-variables />
</component>
</project>

View File

@@ -0,0 +1,6 @@
<component name="InspectionProjectProfileManager">
<profile version="1.0">
<option name="myName" value="Project Default" />
<inspection_tool class="TsLint" enabled="true" level="ERROR" enabled_by_default="true" />
</profile>
</component>

7
.idea/jsLibraryMappings.xml generated Normal file
View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="JavaScriptLibraryMappings">
<file url="PROJECT" libraries="{tf}" />
<includedPredefinedLibrary name="Node.js Core" />
</component>
</project>

14
.idea/kuerbiskern.iml generated Normal file
View File

@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="WEB_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$">
<excludeFolder url="file://$MODULE_DIR$/.tmp" />
<excludeFolder url="file://$MODULE_DIR$/package_info" />
<excludeFolder url="file://$MODULE_DIR$/temp" />
<excludeFolder url="file://$MODULE_DIR$/tmp" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" name="tf" level="application" />
</component>
</module>

6
.idea/misc.xml generated Normal file
View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="JavaScriptSettings">
<option name="languageLevel" value="ES6" />
</component>
</project>

8
.idea/modules.xml generated Normal file
View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/kuerbiskern.iml" filepath="$PROJECT_DIR$/.idea/kuerbiskern.iml" />
</modules>
</component>
</project>

11
.idea/runConfigurations/bin_www.xml generated Normal file
View File

@@ -0,0 +1,11 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="bin/www" type="NodeJSConfigurationType" factoryName="Node.js" path-to-js-file="bin/www" working-dir="$PROJECT_DIR$">
<envs>
<env name="DEBUG" value="kuerbiskern:*" />
</envs>
<EXTENSION ID="com.jetbrains.nodejs.run.NodeJSStartBrowserRunConfigurationExtension">
<browser url="http://localhost:3000/" />
</EXTENSION>
<method v="2" />
</configuration>
</component>

7
.idea/typescript-compiler.xml generated Normal file
View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="TypeScriptCompiler">
<option name="recompileOnChanges" value="true" />
<option name="typeScriptCompilerParams" value="-p" />
</component>
</project>

6
.idea/vcs.xml generated Normal file
View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>

4
.idea/watcherTasks.xml generated Normal file
View File

@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectTasksOptions" suppressed-tasks="Pug/Jade" />
</project>

14
.idea/webResources.xml generated Normal file
View File

@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="WebResourcesPaths">
<contentEntries>
<entry url="file://$PROJECT_DIR$">
<entryData>
<resourceRoots>
<path value="file://$PROJECT_DIR$/public" />
</resourceRoots>
</entryData>
</entry>
</contentEntries>
</component>
</project>

53
app.js Normal file
View File

@@ -0,0 +1,53 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var cookieParser = require("cookie-parser");
var express = require("express");
var createError = require("http-errors");
var low = require("lowdb");
var FileSync = require("lowdb/adapters/FileSync");
var logger = require("morgan");
var path = require("path");
var uuidv4 = require("uuid/v4");
var indexRouter = require("./routes/index");
var usersRouter = require("./routes/users");
var app = express();
var adapter = new FileSync("db.json");
var db = low(adapter);
db.defaults({ users: [] })
.write();
// view engine setup
app.set("views", path.join(__dirname, "views"));
app.set("view engine", "pug");
app.use(logger("dev"));
app.use(express.json());
app.use(express.urlencoded({ extended: false }));
app.use(cookieParser());
app.use(function (req, res, next) {
var user = db.get("users").find({ id: req.cookies.uid }).value();
if (!req.cookies || !req.cookies.uid || !user) {
var id = uuidv4();
db.get("users")
.push({ id: id, age: -1, sex: "na", cocktails: [] })
.write();
res.cookie("uid", id, { maxAge: 21474836470000, httpOnly: true });
}
next();
});
app.use(express.static(path.join(__dirname, "public")));
app.use("/", indexRouter);
app.use("/users", usersRouter);
// catch 404 and forward to error handler
app.use(function (req, res, next) {
next(createError(404));
});
// error handler
app.use(function (err, req, res, next) {
// set locals, only providing error in development
res.locals.message = err.message;
res.locals.error = req.app.get("env") === "development" ? err : {};
// render the error page
res.status(err.status || 500);
res.render("error");
});
module.exports = app;
//# sourceMappingURL=app.js.map

1
app.js.map Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"app.js","sourceRoot":"","sources":["app.ts"],"names":[],"mappings":"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"}

59
app.ts Normal file
View File

@@ -0,0 +1,59 @@
import * as cookieParser from "cookie-parser";
import * as express from "express";
import * as createError from "http-errors";
import * as low from "lowdb";
import * as FileSync from "lowdb/adapters/FileSync";
import * as logger from "morgan";
import * as path from "path";
import * as uuidv4 from "uuid/v4";
import * as indexRouter from "./routes/index";
import * as usersRouter from "./routes/users";
const app = express();
const adapter = new FileSync("db.json")
const db = low(adapter);
db.defaults({users: []})
.write();
// view engine setup
app.set("views", path.join(__dirname, "views"));
app.set("view engine", "pug");
app.use(logger("dev"));
app.use(express.json());
app.use(express.urlencoded({ extended: false }));
app.use(cookieParser());
app.use((req, res, next) => {
const user = db.get("users").find({id: req.cookies.uid}).value();
if (!req.cookies || !req.cookies.uid || !user) {
const id = uuidv4();
db.get("users")
.push({id, age: -1, sex: "na", cocktails: []})
.write();
res.cookie("uid", id, { maxAge: 21474836470000, httpOnly: true });
}
next();
});
app.use(express.static(path.join(__dirname, "public")));
app.use("/", indexRouter);
app.use("/users", usersRouter);
// catch 404 and forward to error handler
app.use((req, res, next) => {
next(createError(404));
});
// error handler
app.use((err, req, res, next) => {
// set locals, only providing error in development
res.locals.message = err.message;
res.locals.error = req.app.get("env") === "development" ? err : {};
// render the error page
res.status(err.status || 500);
res.render("error");
});
module.exports = app;

92
bin/www Normal file
View File

@@ -0,0 +1,92 @@
#!/usr/bin/env node
require('source-map-support').install();
/**
* Module dependencies.
*/
var app = require('../app');
var debug = require('debug')('kuerbiskern:server');
var http = require('http');
/**
* Get port from environment and store in Express.
*/
var port = normalizePort(process.env.PORT || '3000');
app.set('port', port);
/**
* Create HTTP server.
*/
var server = http.createServer(app);
/**
* Listen on provided port, on all network interfaces.
*/
server.listen(port);
server.on('error', onError);
server.on('listening', onListening);
/**
* Normalize a port into a number, string, or false.
*/
function normalizePort(val) {
var port = parseInt(val, 10);
if (isNaN(port)) {
// named pipe
return val;
}
if (port >= 0) {
// port number
return port;
}
return false;
}
/**
* Event listener for HTTP server "error" event.
*/
function onError(error) {
if (error.syscall !== 'listen') {
throw error;
}
var bind = typeof port === 'string'
? 'Pipe ' + port
: 'Port ' + port;
// handle specific listen errors with friendly messages
switch (error.code) {
case 'EACCES':
console.error(bind + ' requires elevated privileges');
process.exit(1);
break;
case 'EADDRINUSE':
console.error(bind + ' is already in use');
process.exit(1);
break;
default:
throw error;
}
}
/**
* Event listener for HTTP server "listening" event.
*/
function onListening() {
var addr = server.address();
var bind = typeof addr === 'string'
? 'pipe ' + addr
: 'port ' + addr.port;
debug('Listening on ' + bind);
}

664
db.json Normal file
View File

@@ -0,0 +1,664 @@
{
"users": [
{
"id": "4b425eb8-00db-42fa-a8c2-cc5418797ad7",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "8f92ce81-0ee6-4f5f-993b-f3627201de72",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "0c446fac-b103-4e72-ac8f-d53d6ecfdb66",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "c8d08c20-5a1c-4b4a-b117-f6aab3613314",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "b6f9e581-d096-4010-af66-0e5bdb0fe9b0",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "bf884005-ac91-4281-a607-97a58eb27d6f",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "f75810f7-a86b-422e-ae15-2db976f21e76",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "860b9922-e129-4ab8-9500-2066a178fc3a",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "0674d1b1-9cda-442a-918e-6ee4546d7aa5",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "e23d34f8-0585-46fb-b889-f4543692ab0e",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "359cdd59-ae6a-4e69-881b-096c5919c23d",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "499d852f-51fb-4120-85b1-0dc20095a083",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "4cc892ee-cd08-42c3-ade6-234eac0f2b3f",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "f9cba44e-536f-4f1c-a84b-15541bef206d",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "0de6fb47-b605-4407-9543-4d1f60e89096",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "21c7c8f5-d2ec-470a-828e-e74ee65add7a",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "57b139a1-7372-4175-b492-4be037132ca3",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "36447975-b1d6-4033-8431-e6c82f0f8b1e",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "a9870bc3-7ac9-40a5-a4c8-33c2a7065f74",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "a0b8075f-abc2-48ff-a02d-a28dbe4ad832",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "4ed2ef03-4d9d-4350-bf9b-1dafeaa09049",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "1aa2de46-ba6a-4257-b539-a29a0a108007",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "964795be-fdf3-4676-a411-65e30b0b5fa9",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "c608597a-2414-40a0-ae2c-757be8e0a514",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "e2fab0f1-0a53-4d3b-b71e-72a0ad117176",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "39cd3c1b-3778-4dc1-a546-1da807d3f032",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "0d2cfe57-e674-4544-b00e-3c49abcf9ea8",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "e4b038a2-fa5b-4bc7-99a3-fedd07d66e38",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "39e96663-428f-41fe-b1e4-1ab2ed0481d4",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "ec7be878-c42c-42b2-b532-acf13a23a20a",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "1d542b6a-9ca5-4754-8b1f-d9cce17ac9fe",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "a5b6ee95-f65c-4354-9fb6-18651b4de23f",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "368d394b-80cd-4d75-ba4b-4a6cf8ca8999",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "ab41bfb1-f4af-4e9b-ad5f-037defedd017",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "83727055-65a7-4955-84ac-81b21ca7caf0",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "95e2ca13-c3ac-4b44-9f4e-1f21ce4e8d3b",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "d3b50d81-9baf-4792-a879-891160594005",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "46c78b02-877e-49b9-9494-c1b85733bea2",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "e149c85c-93ac-41c8-b845-c641b645a00f",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "a8153dde-4acc-46af-914a-a8254f511443",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "60888b41-08c4-419a-a368-e4ddeb58c9b8",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "fa2c61c6-f06b-4dc7-b2b7-a93b2f59e27d",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "7775e577-32a4-4cb1-a6d0-b43df93da83b",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "3bcbdf95-a06d-4890-8d3f-2d06cb47c804",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "7365c6b2-d038-42d4-9b4b-f34d017972e0",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "ccc68f13-52f4-4f71-beb2-5acb2dda4124",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "f366dcb7-1bea-45a2-8f7c-dff9e123d4b9",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "f4c23fa1-1fc7-48f6-a932-b1367fa01deb",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "7ae97e73-498f-4fa2-bd81-d73970c06cb5",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "823bb2f3-2c6f-41eb-a002-fb4d454edd59",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "026d4220-541d-4949-8e77-638bc10fb342",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "475323bb-833f-490a-87a4-30cf36f81364",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "06c8da8d-fdaf-4e3a-a91a-03e485d15594",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "ebe8dcae-ff2c-4e89-9e83-f5d964f9b512",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "3dfb0244-6694-4441-8be7-6936e69b0dc1",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "39a3b742-7aa4-4a70-a618-741f65ac168a",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "ec60f51c-1b98-45c4-9561-de6d5a4726b1",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "c745ddc7-3c94-4679-bead-3526e349d3f6",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "76bb1894-1367-4f12-9cdb-34f0607e1e1f",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "c18934c0-877a-44bf-b341-9d2faeec048b",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "582e20ff-cd8f-4d63-accd-3b19c63a7c07",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "1c42fdc5-3b03-49a2-a7cf-a2885f0d0525",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "e74989f8-e2e7-4936-a2c0-6c9cbff9c94f",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "b2c765c7-9f8a-46fb-9fb3-ca38f53fa5ed",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "5606b7fe-6ee5-4d6c-b113-e8ae1dd941e2",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "5bc41046-dd7e-4b2e-9373-1839b0e3828c",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "c0f4a178-a125-4fd8-b2c7-90de6d7d2100",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "f216fce1-e4bd-493d-95cf-031fbab6ccdf",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "a4dd4b43-30a0-42d5-8eed-31688e9890fb",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "42c72154-f4af-4366-9dd9-5f1e6a723876",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "58183297-d97b-4705-9a54-a124e015d314",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "58162229-f1e6-414b-9f0c-8439087d3129",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "636054f1-c7ed-405b-800d-0631ffd1adb1",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "4a9d5cd8-4ffa-4bc6-8539-76dc8e6559f9",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "3e34cfe8-6aa3-4914-a36a-71c25be299a8",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "f1f0ac36-07b4-4e65-a082-fa0912599cf7",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "2e41d286-eccc-4bae-907c-08b1ee6c1185",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "b47654fe-e84f-4b38-93ca-d4497554f695",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "9c1f53c1-b9a1-4376-9b1b-977f12edb839",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "6c7ea477-36a4-402d-953a-f715d5a32166",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "0c52fff5-15fb-4ea4-914f-e3add836aab8",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "b36fc946-cd65-4a5f-8933-52fdb0ad9340",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "b52c2a96-503f-40e7-b926-cc0b68de32b7",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "8758ada4-a9c6-4c62-a625-1b42a35c70a8",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "c7ff2c6f-8247-4bac-b5ab-7241deeaaa32",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "324c03d3-6e52-41b8-9aed-c497b40ce870",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "1c959355-ac2c-4422-8c13-84fcf13a3e99",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "6b8a5dc0-5928-4ac5-a5e7-d89745c101ed",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "53d9c99a-4ca8-4787-b470-75fb4a44217c",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "690d29c6-e152-416a-be47-908740a1275b",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "ae8a340c-d29c-4498-9282-8a5c9c2eafec",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "59bb0435-6e67-46d4-a637-0d8fd7360427",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "8d403139-b148-4761-9dc4-34c780d7b666",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "2f8fed85-078c-420a-8616-4f23b585782b",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "df6bd7f8-908f-4f6b-9261-aad015d41572",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "a768cf6c-d3b0-452e-a67b-272133601338",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "f057980c-0cba-42ec-9b80-1569047a466b",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "d6c3cbac-7c92-42db-a12f-25cc2c166de1",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "6ecd1fef-d426-4f2d-9dae-0f8eec2edf0f",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "e590742d-df7b-4538-a385-da3f9b735a30",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "24b7969b-7dba-4403-919a-b0c49fcd946f",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "7e4fc28e-a56a-4e13-bbbc-20be9ad21e53",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "d9b59b12-ab55-48fd-b775-974815452a32",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "d8f28599-4bad-40fc-92b8-f2b0d05c5e1a",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "d96d2156-bf96-4375-813e-dd4afcb2e69a",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "1c3a2fa2-8405-4645-995e-cb4bcc8901d2",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "8e5d6f41-fbe3-462b-9054-5252bb726baf",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "a012d03e-236c-4778-a26b-3b64ed2ea423",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "c379f2fe-e5ff-4e73-8032-f3809c82d570",
"age": -1,
"sex": "na",
"cocktails": []
},
{
"id": "f547ecef-348f-4cf8-a6ea-c0e9b1769e15",
"age": -1,
"sex": "na",
"cocktails": []
}
]
}

1978
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

29
package.json Normal file
View File

@@ -0,0 +1,29 @@
{
"name": "kuerbiskern",
"version": "0.0.0",
"private": true,
"scripts": {
"start": "node ./bin/www",
"tsc": "tsc -p"
},
"dependencies": {
"cookie-parser": "~1.4.3",
"debug": "~2.6.9",
"express": "~4.16.0",
"http-errors": "~1.6.2",
"lowdb": "^1.0.0",
"morgan": "~1.9.0",
"pug": "2.0.0-beta11",
"sqlite3": "^4.0.4",
"uuid": "^3.3.2"
},
"devDependencies": {
"@types/express": "^4.16.0",
"@types/lowdb": "^1.0.6",
"@types/node": "^10.12.10",
"@types/sqlite3": "^3.1.3",
"source-map-support": "^0.5.9",
"tslint": "^5.11.0",
"typescript": "^3.1.6"
}
}

View File

@@ -0,0 +1,3 @@
600;Sex on the Beach;590;450;Vodka;Menonenlikör;Pfirsichlikör;Melonensirup;Zitronensaft;Ananasaft;Grenadine
601;Sex in the Snow;590;450;Vodka;Weißer Rum;Cranberrysirup;Sahne;Maracuja-Nektar
602;Zungenkuss;550;450;Vodka;Mandelsirup;Kokossirup;Sahne;Kirsch-Nektar
1 600;Sex on the Beach;590;450;Vodka;Menonenlikör;Pfirsichlikör;Melonensirup;Zitronensaft;Ananasaft;Grenadine
2 601;Sex in the Snow;590;450;Vodka;Weißer Rum;Cranberrysirup;Sahne;Maracuja-Nektar
3 602;Zungenkuss;550;450;Vodka;Mandelsirup;Kokossirup;Sahne;Kirsch-Nektar

View File

@@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2014-2018 Materialize
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

View File

@@ -0,0 +1 @@
{"modelTopology": {"backend": "tensorflow", "keras_version": "2.0.9", "model_config": {"class_name": "Model", "config": {"input_layers": [["input_1", 0, 0]], "output_layers": [["dense_6", 0, 0]], "layers": [{"class_name": "InputLayer", "config": {"dtype": "float32", "sparse": false, "batch_input_shape": [null, 82], "name": "input_1"}, "inbound_nodes": [], "name": "input_1"}, {"class_name": "Dense", "config": {"bias_initializer": {"class_name": "Zeros", "config": {}}, "bias_constraint": null, "kernel_regularizer": null, "bias_regularizer": null, "activity_regularizer": null, "kernel_initializer": {"class_name": "VarianceScaling", "config": {"mode": "fan_avg", "scale": 1.0, "distribution": "uniform", "seed": null}}, "name": "dense_1", "kernel_constraint": null, "use_bias": true, "activation": "tanh", "trainable": true, "units": 70}, "inbound_nodes": [[["input_1", 0, 0, {}]]], "name": "dense_1"}, {"class_name": "Dense", "config": {"bias_initializer": {"class_name": "Zeros", "config": {}}, "bias_constraint": null, "kernel_regularizer": null, "bias_regularizer": null, "activity_regularizer": null, "kernel_initializer": {"class_name": "VarianceScaling", "config": {"mode": "fan_avg", "scale": 1.0, "distribution": "uniform", "seed": null}}, "name": "dense_2", "kernel_constraint": null, "use_bias": true, "activation": "tanh", "trainable": true, "units": 40}, "inbound_nodes": [[["dense_1", 0, 0, {}]]], "name": "dense_2"}, {"class_name": "Dense", "config": {"bias_initializer": {"class_name": "Zeros", "config": {}}, "bias_constraint": null, "kernel_regularizer": null, "bias_regularizer": null, "activity_regularizer": null, "kernel_initializer": {"class_name": "VarianceScaling", "config": {"mode": "fan_avg", "scale": 1.0, "distribution": "uniform", "seed": null}}, "name": "dense_3", "kernel_constraint": null, "use_bias": true, "activation": "tanh", "trainable": true, "units": 2}, "inbound_nodes": [[["dense_2", 0, 0, {}]]], "name": "dense_3"}, {"class_name": "Dense", "config": {"bias_initializer": {"class_name": "Zeros", "config": {}}, "bias_constraint": null, "kernel_regularizer": null, "bias_regularizer": null, "activity_regularizer": null, "kernel_initializer": {"class_name": "VarianceScaling", "config": {"mode": "fan_avg", "scale": 1.0, "distribution": "uniform", "seed": null}}, "name": "dense_4", "kernel_constraint": null, "use_bias": true, "activation": "tanh", "trainable": true, "units": 70}, "inbound_nodes": [[["dense_3", 0, 0, {}]]], "name": "dense_4"}, {"class_name": "Dense", "config": {"bias_initializer": {"class_name": "Zeros", "config": {}}, "bias_constraint": null, "kernel_regularizer": null, "bias_regularizer": null, "activity_regularizer": null, "kernel_initializer": {"class_name": "VarianceScaling", "config": {"mode": "fan_avg", "scale": 1.0, "distribution": "uniform", "seed": null}}, "name": "dense_5", "kernel_constraint": null, "use_bias": true, "activation": "tanh", "trainable": true, "units": 40}, "inbound_nodes": [[["dense_4", 0, 0, {}]]], "name": "dense_5"}, {"class_name": "Dense", "config": {"bias_initializer": {"class_name": "Zeros", "config": {}}, "bias_constraint": null, "kernel_regularizer": null, "bias_regularizer": null, "activity_regularizer": null, "kernel_initializer": {"class_name": "VarianceScaling", "config": {"mode": "fan_avg", "scale": 1.0, "distribution": "uniform", "seed": null}}, "name": "dense_6", "kernel_constraint": null, "use_bias": true, "activation": "sigmoid", "trainable": true, "units": 82}, "inbound_nodes": [[["dense_5", 0, 0, {}]]], "name": "dense_6"}], "name": "model_1"}}, "training_config": {"loss_weights": null, "optimizer_config": {"class_name": "Adadelta", "config": {"epsilon": 1e-08, "decay": 0.0, "rho": 0.95, "lr": 1.0}}, "loss": "binary_crossentropy", "metrics": ["binary_accuracy"], "sample_weight_mode": null}}, "weightsManifest": [{"paths": ["group1-shard1of1"], "weights": [{"shape": [82, 70], "dtype": "float32", "name": "dense_1/kernel"}, {"shape": [70], "dtype": "float32", "name": "dense_1/bias"}, {"shape": [70, 40], "dtype": "float32", "name": "dense_2/kernel"}, {"shape": [40], "dtype": "float32", "name": "dense_2/bias"}, {"shape": [40, 2], "dtype": "float32", "name": "dense_3/kernel"}, {"shape": [2], "dtype": "float32", "name": "dense_3/bias"}, {"shape": [2, 70], "dtype": "float32", "name": "dense_4/kernel"}, {"shape": [70], "dtype": "float32", "name": "dense_4/bias"}, {"shape": [70, 40], "dtype": "float32", "name": "dense_5/kernel"}, {"shape": [40], "dtype": "float32", "name": "dense_5/bias"}, {"shape": [40, 82], "dtype": "float32", "name": "dense_6/kernel"}, {"shape": [82], "dtype": "float32", "name": "dense_6/bias"}]}]}

View File

@@ -0,0 +1 @@
{"modelTopology": {"backend": "tensorflow", "model_config": {"config": {"layers": [{"config": {"batch_input_shape": [null, 2], "sparse": false, "name": "input_2", "dtype": "float32"}, "inbound_nodes": [], "class_name": "InputLayer", "name": "input_2"}, {"config": {"bias_initializer": {"config": {}, "class_name": "Zeros"}, "use_bias": true, "units": 70, "activity_regularizer": null, "activation": "tanh", "name": "dense_4", "kernel_initializer": {"config": {"scale": 1.0, "seed": null, "mode": "fan_avg", "distribution": "uniform"}, "class_name": "VarianceScaling"}, "bias_constraint": null, "bias_regularizer": null, "kernel_constraint": null, "trainable": true, "kernel_regularizer": null}, "inbound_nodes": [[["input_2", 0, 0, {}]]], "class_name": "Dense", "name": "dense_4"}, {"config": {"bias_initializer": {"config": {}, "class_name": "Zeros"}, "use_bias": true, "units": 40, "activity_regularizer": null, "activation": "tanh", "name": "dense_5", "kernel_initializer": {"config": {"scale": 1.0, "seed": null, "mode": "fan_avg", "distribution": "uniform"}, "class_name": "VarianceScaling"}, "bias_constraint": null, "bias_regularizer": null, "kernel_constraint": null, "trainable": true, "kernel_regularizer": null}, "inbound_nodes": [[["dense_4", 0, 0, {}]]], "class_name": "Dense", "name": "dense_5"}, {"config": {"bias_initializer": {"config": {}, "class_name": "Zeros"}, "use_bias": true, "units": 82, "activity_regularizer": null, "activation": "sigmoid", "name": "dense_6", "kernel_initializer": {"config": {"scale": 1.0, "seed": null, "mode": "fan_avg", "distribution": "uniform"}, "class_name": "VarianceScaling"}, "bias_constraint": null, "bias_regularizer": null, "kernel_constraint": null, "trainable": true, "kernel_regularizer": null}, "inbound_nodes": [[["dense_5", 0, 0, {}]]], "class_name": "Dense", "name": "dense_6"}], "input_layers": [["input_2", 0, 0]], "name": "model_3", "output_layers": [["dense_6", 0, 0]]}, "class_name": "Model"}, "keras_version": "2.0.9"}, "weightsManifest": [{"paths": ["group1-shard1of1"], "weights": [{"shape": [2, 70], "name": "dense_4/kernel", "dtype": "float32"}, {"shape": [70], "name": "dense_4/bias", "dtype": "float32"}, {"shape": [70, 40], "name": "dense_5/kernel", "dtype": "float32"}, {"shape": [40], "name": "dense_5/bias", "dtype": "float32"}, {"shape": [40, 82], "name": "dense_6/kernel", "dtype": "float32"}, {"shape": [82], "name": "dense_6/bias", "dtype": "float32"}]}]}

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1 @@
{"modelTopology": {"model_config": {"config": {"name": "model_2", "layers": [{"name": "input_1", "config": {"name": "input_1", "dtype": "float32", "batch_input_shape": [null, 82], "sparse": false}, "class_name": "InputLayer", "inbound_nodes": []}, {"name": "dense_1", "config": {"kernel_regularizer": null, "kernel_initializer": {"config": {"scale": 1.0, "seed": null, "mode": "fan_avg", "distribution": "uniform"}, "class_name": "VarianceScaling"}, "use_bias": true, "trainable": true, "activation": "tanh", "units": 70, "bias_constraint": null, "activity_regularizer": null, "bias_regularizer": null, "name": "dense_1", "bias_initializer": {"config": {}, "class_name": "Zeros"}, "kernel_constraint": null}, "class_name": "Dense", "inbound_nodes": [[["input_1", 0, 0, {}]]]}, {"name": "dense_2", "config": {"kernel_regularizer": null, "kernel_initializer": {"config": {"scale": 1.0, "seed": null, "mode": "fan_avg", "distribution": "uniform"}, "class_name": "VarianceScaling"}, "use_bias": true, "trainable": true, "activation": "tanh", "units": 40, "bias_constraint": null, "activity_regularizer": null, "bias_regularizer": null, "name": "dense_2", "bias_initializer": {"config": {}, "class_name": "Zeros"}, "kernel_constraint": null}, "class_name": "Dense", "inbound_nodes": [[["dense_1", 0, 0, {}]]]}, {"name": "dense_3", "config": {"kernel_regularizer": null, "kernel_initializer": {"config": {"scale": 1.0, "seed": null, "mode": "fan_avg", "distribution": "uniform"}, "class_name": "VarianceScaling"}, "use_bias": true, "trainable": true, "activation": "tanh", "units": 2, "bias_constraint": null, "activity_regularizer": null, "bias_regularizer": null, "name": "dense_3", "bias_initializer": {"config": {}, "class_name": "Zeros"}, "kernel_constraint": null}, "class_name": "Dense", "inbound_nodes": [[["dense_2", 0, 0, {}]]]}], "input_layers": [["input_1", 0, 0]], "output_layers": [["dense_3", 0, 0]]}, "class_name": "Model"}, "backend": "tensorflow", "keras_version": "2.0.9"}, "weightsManifest": [{"weights": [{"name": "dense_1/kernel", "dtype": "float32", "shape": [82, 70]}, {"name": "dense_1/bias", "dtype": "float32", "shape": [70]}, {"name": "dense_2/kernel", "dtype": "float32", "shape": [70, 40]}, {"name": "dense_2/bias", "dtype": "float32", "shape": [40]}, {"name": "dense_3/kernel", "dtype": "float32", "shape": [40, 2]}, {"name": "dense_3/bias", "dtype": "float32", "shape": [2]}], "paths": ["group1-shard1of1"]}]}

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 252 KiB

2
public/js/getmdl-select.min.js vendored Normal file
View File

@@ -0,0 +1,2 @@
"use strict";!function(){function e(){getmdlSelect.init(".getmdl-select")}window.addEventListener?window.addEventListener("load",e,!1):window.attachEvent&&window.attachEvent("onload",e)}();var getmdlSelect={_defaultValue:{width:300},_addEventListeners:function(e){var t=e.querySelector("input"),n=e.querySelector('input[type="hidden"]'),l=e.querySelectorAll("li"),a=e.querySelector(".mdl-js-menu"),o=e.querySelector(".mdl-icon-toggle__label"),i="",c="",s="",u=!1,d=function(o){var i=o.textContent.trim();if(t.value=i,l.forEach(function(e){e.classList.remove("selected")}),o.classList.add("selected"),e.MaterialTextfield.change(i),setTimeout(function(){e.MaterialTextfield.updateClasses_()},250),n.value=o.dataset.val||"",c=t.value,s=n.value,"createEvent"in document){var u=document.createEvent("HTMLEvents");u.initEvent("change",!1,!0),a.MaterialMenu.hide(),t.dispatchEvent(u)}else t.fireEvent("onchange")},r=function(){u=!1,t.value=c,n.value=s,e.querySelector(".mdl-menu__container").classList.contains("is-visible")||e.classList.remove("is-focused");var l=document.querySelectorAll(".getmdl-select .mdl-js-menu");[].forEach.call(l,function(e){e.MaterialMenu.hide()});var o=new Event("closeSelect");a.dispatchEvent(o)};document.body.addEventListener("click",r,!1),e.onkeydown=function(l){9==l.keyCode&&(t.value=c,n.value=s,a.MaterialMenu.hide(),e.classList.remove("is-focused"))},t.onfocus=function(e){a.MaterialMenu.show(),a.focus(),u=!0},t.onblur=function(e){e.stopPropagation()},t.onclick=function(t){t.stopPropagation(),a.classList.contains("is-visible")?(a.MaterialMenu.hide(),u=!1):(a.MaterialMenu.show(),r(),e.classList.add("is-focused"),u=!0)},t.onkeydown=function(l){27==l.keyCode&&(t.value=c,n.value=s,a.MaterialMenu.hide(),e.MaterialTextfield.onBlur_(),""!==i&&(e.querySelector(".mdl-textfield__label").textContent=i,i=""))},a.addEventListener("closeSelect",function(l){t.value=c,n.value=s,e.classList.remove("is-focused"),""!==i&&(e.querySelector(".mdl-textfield__label").textContent=i,i="")}),a.onkeydown=function(l){27==l.keyCode&&(t.value=c,n.value=s,e.classList.remove("is-focused"),""!==i&&(e.querySelector(".mdl-textfield__label").textContent=i,i=""))},o&&(o.onclick=function(l){l.stopPropagation(),u?(a.MaterialMenu.hide(),u=!1,e.classList.remove("is-focused"),e.MaterialTextfield.onBlur_(),t.value=c,n.value=s):(r(),e.MaterialTextfield.onFocus_(),t.focus(),a.MaterialMenu.show(),u=!0)}),[].forEach.call(l,function(n){n.onfocus=function(){e.classList.add("is-focused");var l=n.textContent.trim();t.value=l,e.classList.contains("mdl-textfield--floating-label")||""!=i||(i=e.querySelector(".mdl-textfield__label").textContent.trim(),e.querySelector(".mdl-textfield__label").textContent="")},n.onclick=function(){d(n)},n.dataset.selected&&d(n)})},init:function(e){var t=document.querySelectorAll(e);[].forEach.call(t,function(e){getmdlSelect._addEventListeners(e),componentHandler.upgradeElement(e),componentHandler.upgradeElement(e.querySelector("ul"))})}};
//# sourceMappingURL=getmdl-select.min.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":["src\\js\\getmdl-select.js"],"names":["whenLoaded","getmdlSelect","init","window","addEventListener","attachEvent","_defaultValue","width","_addEventListeners","dropdown","input","querySelector","hiddenInput","list","querySelectorAll","menu","arrow","label","previousValue","previousDataVal","opened","setSlectedItem","li","value","textContent","trim","forEach","classList","remove","add","MaterialTextfield","change","setTimeout","updateClasses_","dataset","val","document","evt","createEvent","initEvent","hide","dispatchEvent","fireEvent","hideAllMenus","contains","menus","call","event","Event","body","onkeydown","keyCode","onfocus","e","show","focus","onblur","stopPropagation","onclick","onBlur_","onFocus_","selected","selector","dropdowns","componentHandler","upgradeElement"],"mappings":"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","file":"getmdl-select.min.js","sourceRoot":"E:\\html5\\GitHub\\getmdl-select"}

24505
public/js/keras.js Normal file

File diff suppressed because it is too large Load Diff

1
public/js/keras.min.js vendored Normal file

File diff suppressed because one or more lines are too long

3996
public/js/material.js Normal file

File diff suppressed because it is too large Load Diff

10
public/js/material.min.js vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,202 @@
(function() {
'use strict';
/**
* Class constructor for Select field MDL component.
* Implements custom MDL component design pattern not defined yet.
*
* @constructor
* @param {HTMLElement} element The element that will be upgraded.
*/
var MaterialSelectfield = function MaterialSelectfield(element) {
this.element_ = element;
// Initialize instance.
this.init();
};
window['MaterialSelectfield'] = MaterialSelectfield;
MaterialSelectfield.prototype.Constant_ = {
// None for now
};
MaterialSelectfield.prototype.CssClasses_ = {
LABEL: 'mdl-selectfield__label',
SELECT: 'mdl-selectfield__select',
IS_DIRTY: 'is-dirty',
IS_FOCUSED: 'is-focused',
IS_DISABLED: 'is-disabled',
IS_INVALID: 'is-invalid',
IS_UPGRADED: 'is-upgraded'
};
/**
* Handle focus.
*
* @param {Event} event The event that fired.
* @private
*/
MaterialSelectfield.prototype.onFocus_ = function(event) {
this.element_.classList.add(this.CssClasses_.IS_FOCUSED);
};
/**
* Handle lost focus.
*
* @param {Event} event The event that fired.
* @private
*/
MaterialSelectfield.prototype.onBlur_ = function(event) {
this.element_.classList.remove(this.CssClasses_.IS_FOCUSED);
};
/**
* Handle reset event from outside.
*
* @param {Event} event The event that fired.
* @private
*/
MaterialSelectfield.prototype.onReset_ = function(event) {
this.updateClasses_();
};
/**
* Handle class updates.
*
* @private
*/
MaterialSelectfield.prototype.updateClasses_ = function() {
this.checkDisabled();
this.checkValidity();
this.checkDirty();
};
// Public methods.
/**
* Check the disabled state and update field accordingly.
*
* @public
*/
MaterialSelectfield.prototype.checkDisabled = function() {
if (this.select_.disabled) {
this.element_.classList.add(this.CssClasses_.IS_DISABLED);
} else {
this.element_.classList.remove(this.CssClasses_.IS_DISABLED);
}
};
MaterialSelectfield.prototype['checkDisabled'] = MaterialSelectfield.prototype.checkDisabled;
/**
* Check the validity state and update field accordingly.
*
* @public
*/
MaterialSelectfield.prototype.checkValidity = function() {
if (this.select_.validity.valid) {
this.element_.classList.remove(this.CssClasses_.IS_INVALID);
} else {
this.element_.classList.add(this.CssClasses_.IS_INVALID);
}
};
MaterialSelectfield.prototype['checkValidity'] = MaterialSelectfield.prototype.checkValidity;
/**
* Check the dirty state and update field accordingly.
*
* @public
*/
MaterialSelectfield.prototype.checkDirty = function() {
if (this.select_.value && this.select_.value.length > 0) {
this.element_.classList.add(this.CssClasses_.IS_DIRTY);
} else {
this.element_.classList.remove(this.CssClasses_.IS_DIRTY);
}
};
MaterialSelectfield.prototype['checkDirty'] = MaterialSelectfield.prototype.checkDirty;
/**
* Enable select field.
*
* @public
*/
MaterialSelectfield.prototype.disable = function() {
this.select_.disabled = true;
this.updateClasses_();
};
MaterialSelectfield.prototype['disable'] = MaterialSelectfield.prototype.disable;
/**
* Enable select field.
*
* @public
*/
MaterialSelectfield.prototype.enable = function() {
this.select_.disabled = false;
this.updateClasses_();
};
MaterialSelectfield.prototype['enable'] = MaterialSelectfield.prototype.enable;
/**
* Update select field value.
*
* @param {string} value The value to which to set the control (optional).
* @public
*/
MaterialSelectfield.prototype.change = function(value) {
if (value) {
this.select_.value = value;
}
this.updateClasses_();
};
MaterialSelectfield.prototype['change'] = MaterialSelectfield.prototype.change;
/**
* Initialize element.
*/
MaterialSelectfield.prototype.init = function() {
if (this.element_) {
this.label_ = this.element_.querySelector('.' + this.CssClasses_.LABEL);
this.select_ = this.element_.querySelector('.' + this.CssClasses_.SELECT);
if (this.select_) {
this.boundUpdateClassesHandler = this.updateClasses_.bind(this);
this.boundFocusHandler = this.onFocus_.bind(this);
this.boundBlurHandler = this.onBlur_.bind(this);
this.boundResetHandler = this.onReset_.bind(this);
this.select_.addEventListener('change', this.boundUpdateClassesHandler);
this.select_.addEventListener('focus', this.boundFocusHandler);
this.select_.addEventListener('blur', this.boundBlurHandler);
this.select_.addEventListener('reset', this.boundResetHandler);
var invalid = this.element_.classList
.contains(this.CssClasses_.IS_INVALID);
this.updateClasses_();
this.element_.classList.add(this.CssClasses_.IS_UPGRADED);
if (invalid) {
this.element_.classList.add(this.CssClasses_.IS_INVALID);
}
}
}
};
/**
* Downgrade the component
*
* @private
*/
MaterialSelectfield.prototype.mdlDowngrade_ = function() {
this.select_.removeEventListener('change', this.boundUpdateClassesHandler);
this.select_.removeEventListener('focus', this.boundFocusHandler);
this.select_.removeEventListener('blur', this.boundBlurHandler);
this.select_.removeEventListener('reset', this.boundResetHandler);
};
// The component registers itself. It can assume componentHandler is available
// in the global scope.
componentHandler.register({
constructor: MaterialSelectfield,
classAsString: 'MaterialSelectfield',
cssClass: 'mdl-js-selectfield',
widget: true
});
})();

2
public/js/mdl-selectfield.min.js vendored Normal file
View File

@@ -0,0 +1,2 @@
!function(){"use strict";var s=function(s){this.element_=s,this.init()};window.MaterialSelectfield=s,s.prototype.Constant_={},s.prototype.CssClasses_={LABEL:"mdl-selectfield__label",SELECT:"mdl-selectfield__select",IS_DIRTY:"is-dirty",IS_FOCUSED:"is-focused",IS_DISABLED:"is-disabled",IS_INVALID:"is-invalid",IS_UPGRADED:"is-upgraded"},s.prototype.onFocus_=function(s){this.element_.classList.add(this.CssClasses_.IS_FOCUSED)},s.prototype.onBlur_=function(s){this.element_.classList.remove(this.CssClasses_.IS_FOCUSED)},s.prototype.onReset_=function(s){this.updateClasses_()},s.prototype.updateClasses_=function(){this.checkDisabled(),this.checkValidity(),this.checkDirty()},s.prototype.checkDisabled=function(){this.select_.disabled?this.element_.classList.add(this.CssClasses_.IS_DISABLED):this.element_.classList.remove(this.CssClasses_.IS_DISABLED)},s.prototype.checkDisabled=s.prototype.checkDisabled,s.prototype.checkValidity=function(){this.select_.validity.valid?this.element_.classList.remove(this.CssClasses_.IS_INVALID):this.element_.classList.add(this.CssClasses_.IS_INVALID)},s.prototype.checkValidity=s.prototype.checkValidity,s.prototype.checkDirty=function(){this.select_.value&&this.select_.value.length>0?this.element_.classList.add(this.CssClasses_.IS_DIRTY):this.element_.classList.remove(this.CssClasses_.IS_DIRTY)},s.prototype.checkDirty=s.prototype.checkDirty,s.prototype.disable=function(){this.select_.disabled=!0,this.updateClasses_()},s.prototype.disable=s.prototype.disable,s.prototype.enable=function(){this.select_.disabled=!1,this.updateClasses_()},s.prototype.enable=s.prototype.enable,s.prototype.change=function(s){s&&(this.select_.value=s),this.updateClasses_()},s.prototype.change=s.prototype.change,s.prototype.init=function(){if(this.element_&&(this.label_=this.element_.querySelector("."+this.CssClasses_.LABEL),this.select_=this.element_.querySelector("."+this.CssClasses_.SELECT),this.select_)){this.boundUpdateClassesHandler=this.updateClasses_.bind(this),this.boundFocusHandler=this.onFocus_.bind(this),this.boundBlurHandler=this.onBlur_.bind(this),this.boundResetHandler=this.onReset_.bind(this),this.select_.addEventListener("change",this.boundUpdateClassesHandler),this.select_.addEventListener("focus",this.boundFocusHandler),this.select_.addEventListener("blur",this.boundBlurHandler),this.select_.addEventListener("reset",this.boundResetHandler);var s=this.element_.classList.contains(this.CssClasses_.IS_INVALID);this.updateClasses_(),this.element_.classList.add(this.CssClasses_.IS_UPGRADED),s&&this.element_.classList.add(this.CssClasses_.IS_INVALID)}},s.prototype.mdlDowngrade_=function(){this.select_.removeEventListener("change",this.boundUpdateClassesHandler),this.select_.removeEventListener("focus",this.boundFocusHandler),this.select_.removeEventListener("blur",this.boundBlurHandler),this.select_.removeEventListener("reset",this.boundResetHandler)},componentHandler.register({constructor:s,classAsString:"MaterialSelectfield",cssClass:"mdl-js-selectfield",widget:!0})}();
//# sourceMappingURL=mdl-selectfield.min.js.map

13
public/js/neuralnet.js Normal file
View File

@@ -0,0 +1,13 @@
console.log("hello");
tf.loadModel("/data/adadelta10-1024tanh-decoder-tfmodel/model.json")
.then((model) => {
console.log("HURRAY");
var prediction = model.predict(tf.tensor2d([[0.0, 0.0]], [1, 2]));
prediction.data().then((pred) => {
console.log("prediction", pred);
}).catch((err2) => console.error("err2", err2));
}).catch((err) => {
console.error(err);
});

View File

@@ -0,0 +1,3 @@
.getmdl-select{outline:none}.getmdl-select .mdl-textfield__input{cursor:pointer}.getmdl-select .selected{background-color:#ddd}.getmdl-select .mdl-icon-toggle__label{float:right;margin-top:-30px;color:rgba(0,0,0,0.4);transform:rotate(0);transition:transform 0.3s}.getmdl-select.is-focused .mdl-icon-toggle__label{color:#3f51b5;transform:rotate(180deg)}.getmdl-select .mdl-menu__container{width:100% !important;margin-top:2px}.getmdl-select .mdl-menu__container .mdl-menu{width:100%}.getmdl-select .mdl-menu__container .mdl-menu .mdl-menu__item{font-size:16px}.getmdl-select__fix-height .mdl-menu__container .mdl-menu{overflow-y:auto;max-height:288px !important}.getmdl-select__fix-height .mdl-menu.mdl-menu--top-left{bottom:auto;top:0}
/*# sourceMappingURL=getmdl-select.min.css.map */

View File

@@ -0,0 +1 @@
{"version":3,"file":"getmdl-select.min.css","sources":["getmdl-select.scss"],"sourcesContent":[".getmdl-select {\r\n outline: none;\r\n .mdl-textfield__input {\r\n cursor: pointer;\r\n }\r\n .selected {\r\n background-color: #ddd;\r\n }\r\n .mdl-icon-toggle__label {\r\n float: right;\r\n margin-top: -30px;\r\n color: rgba(0, 0, 0, 0.4);\r\n transform: rotate(0);\r\n transition: transform 0.3s;\r\n }\r\n &.is-focused {\r\n .mdl-icon-toggle__label {\r\n color: #3f51b5;\r\n transform: rotate(180deg);\r\n }\r\n }\r\n\r\n .mdl-menu__container {\r\n width: 100% !important;\r\n margin-top: 2px;\r\n .mdl-menu {\r\n width: 100%;\r\n .mdl-menu__item {\r\n font-size: 16px;\r\n }\r\n }\r\n }\r\n}\r\n\r\n.getmdl-select__fix-height {\r\n .mdl-menu__container .mdl-menu {\r\n overflow-y: auto;\r\n max-height: 288px !important;\r\n }\r\n .mdl-menu.mdl-menu--top-left {\r\n bottom: auto;\r\n top: 0;\r\n }\r\n}"],"mappings":"AAAA,AAAA,cAAc,AAAC,CACb,OAAO,CAAE,IAAK,CA+Bf,AAhCD,AAEE,cAFY,CAEZ,qBAAqB,AAAC,CACpB,MAAM,CAAE,OAAQ,CACjB,AAJH,AAKE,cALY,CAKZ,SAAS,AAAC,CACR,gBAAgB,CAAE,IAAK,CACxB,AAPH,AAQE,cARY,CAQZ,uBAAuB,AAAC,CACtB,KAAK,CAAE,KAAM,CACb,UAAU,CAAE,KAAM,CAClB,KAAK,CAAE,eAAI,CACX,SAAS,CAAE,SAAM,CACjB,UAAU,CAAE,cAAe,CAC5B,AAdH,AAgBI,cAhBU,AAeX,WAAW,CACV,uBAAuB,AAAC,CACtB,KAAK,CAAE,OAAQ,CACf,SAAS,CAAE,cAAM,CAClB,AAnBL,AAsBE,cAtBY,CAsBZ,oBAAoB,AAAC,CACnB,KAAK,CAAE,eAAgB,CACvB,UAAU,CAAE,GAAI,CAOjB,AA/BH,AAyBI,cAzBU,CAsBZ,oBAAoB,CAGlB,SAAS,AAAC,CACR,KAAK,CAAE,IAAK,CAIb,AA9BL,AA2BM,cA3BQ,CAsBZ,oBAAoB,CAGlB,SAAS,CAEP,eAAe,AAAC,CACd,SAAS,CAAE,IAAK,CACjB,AAKP,AACuB,0BADG,CACxB,oBAAoB,CAAC,SAAS,AAAC,CAC7B,UAAU,CAAE,IAAK,CACjB,UAAU,CAAE,gBAAiB,CAC9B,AAJH,AAKW,0BALe,CAKxB,SAAS,AAAA,mBAAmB,AAAC,CAC3B,MAAM,CAAE,IAAK,CACb,GAAG,CAAE,CAAE,CACR","names":[]}

View File

@@ -0,0 +1,22 @@
@font-face {
font-family: 'Material Icons';
font-style: normal;
font-weight: 400;
src: url(https://fonts.gstatic.com/s/materialicons/v41/flUhRq6tzZclQEJ-Vdg-IuiaDsNc.woff2) format('woff2');
}
.material-icons {
font-family: 'Material Icons', sans-serif;
font-weight: normal;
font-style: normal;
font-size: 24px;
line-height: 1;
letter-spacing: normal;
text-transform: none;
display: inline-block;
white-space: nowrap;
word-wrap: normal;
direction: ltr;
-moz-font-feature-settings: 'liga';
-moz-osx-font-smoothing: grayscale;
}

File diff suppressed because it is too large Load Diff

9
public/stylesheets/material.min.css vendored Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,290 @@
/**
* Copyright 2015 Google Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*------------------------------------* $CONTENTS
\*------------------------------------*/
/**
* STYLE GUIDE VARIABLES------------------Declarations of Sass variables
* -----Typography
* -----Colors
* -----Textfield
* -----Switch
* -----Spinner
* -----Radio
* -----Menu
* -----List
* -----Layout
* -----Icon toggles
* -----Footer
* -----Column
* -----Checkbox
* -----Card
* -----Button
* -----Animation
* -----Progress
* -----Badge
* -----Shadows
* -----Grid
* -----Data table
* -----Dialog
* -----Snackbar
*
* Even though all variables have the `!default` directive, most of them
* should not be changed as they are dependent one another. This can cause
* visual distortions (like alignment issues) that are hard to track down
* and fix.
*/
/* ========== TYPOGRAPHY ========== */
/* We're splitting fonts into "preferred" and "performance" in order to optimize
page loading. For important text, such as the body, we want it to load
immediately and not wait for the web font load, whereas for other sections,
such as headers and titles, we're OK with things taking a bit longer to load.
We do have some optional classes and parameters in the mixins, in case you
definitely want to make sure you're using the preferred font and don't mind
the performance hit.
We should be able to improve on this once CSS Font Loading L3 becomes more
widely available.
*/
/* ========== COLORS ========== */
/**
*
* Material design color palettes.
* @see http://www.google.com/design/spec/style/color.html
*
**/
/**
* Copyright 2015 Google Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* ========== Color Palettes ========== */
/* colors.scss */
/**
* Copyright 2015 Google Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* ========== IMAGES ========== */
/* ========== Color & Themes ========== */
/* ========== Typography ========== */
/* ========== Components ========== */
/* ========== Standard Buttons ========== */
/* ========== Icon Toggles ========== */
/* ========== Radio Buttons ========== */
/* ========== Ripple effect ========== */
/* ========== Layout ========== */
/* ========== Content Tabs ========== */
/* ========== Checkboxes ========== */
/* ========== Switches ========== */
/* ========== Spinner ========== */
/* ========== Text fields ========== */
/* ========== Card ========== */
/* ========== Sliders ========== */
/* ========== Progress ========== */
/* ========== List ========== */
/* ========== Item ========== */
/* ========== Dropdown menu ========== */
/* ========== Tooltips ========== */
/* ========== Footer ========== */
/* TEXTFIELD */
/* SWITCH */
/* SPINNER */
/* RADIO */
/* MENU */
/* LIST */
/* LAYOUT */
/* ICON TOGGLE */
/* FOOTER */
/*mega-footer*/
/*mini-footer*/
/* CHECKBOX */
/* CARD */
/* Card dimensions */
/* Cover image */
/* BUTTON */
/**
*
* Dimensions
*
*/
/* ANIMATION */
/* PROGRESS */
/* BADGE */
/* SHADOWS */
/* GRID */
/* DATA TABLE */
/* DIALOG */
/* SNACKBAR */
/* TOOLTIP */
/**
* Copyright 2015 Google Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/* Typography */
/* Shadows */
/* Animations */
/* Dialog */
.mdl-selectfield {
position: relative;
font-size: 16px;
display: inline-block;
box-sizing: border-box;
width: 300px;
max-width: 100%;
margin: 0;
padding: 20px 0; }
.mdl-selectfield--align-right {
text-align: right; }
.mdl-selectfield--full-width {
width: 100%; }
.mdl-selectfield__select {
display: block;
width: 100%;
padding: 4px 0;
margin: 0;
color: inherit;
background: transparent;
font-size: 16px;
text-align: left;
border: none;
border-bottom: 1px solid rgba(0,0,0, 0.12);
border-radius: 0;
-webkit-appearance: none;
-moz-appearance: none;
-ms-appearance: none;
appearance: none; }
.mdl-selectfield__select::-ms-expand {
display: none; }
.mdl-selectfield.is-focused .mdl-selectfield__select {
outline: none; }
.mdl-selectfield.is-invalid .mdl-selectfield__select {
border-color: rgb(222, 50, 38);
box-shadow: none; }
fieldset[disabled] .mdl-selectfield .mdl-selectfield__select, .mdl-selectfield.is-disabled .mdl-selectfield__select {
background-color: transparent;
border-bottom: 1px dotted rgba(0,0,0, 0.12);
color: rgba(0,0,0, 0.26); }
.mdl-selectfield__label {
bottom: 0;
color: rgba(0,0,0, 0.26);
font-size: 16px;
left: 0;
right: 0;
pointer-events: none;
position: absolute;
display: block;
top: 24px;
width: 100%;
overflow: hidden;
white-space: nowrap;
text-align: left; }
.mdl-selectfield.is-dirty .mdl-selectfield__label {
visibility: hidden; }
.mdl-selectfield--floating-label .mdl-selectfield__label {
transition-duration: 0.2s;
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); }
fieldset[disabled] .mdl-selectfield .mdl-selectfield__label,
.mdl-selectfield.is-disabled.is-disabled .mdl-selectfield__label {
color: rgba(0,0,0, 0.26); }
.mdl-selectfield--floating-label.is-focused .mdl-selectfield__label,
.mdl-selectfield--floating-label.is-dirty .mdl-selectfield__label {
color: rgb(63,81,181);
font-size: 12px;
top: 4px;
visibility: visible; }
.mdl-selectfield--floating-label.is-invalid .mdl-selectfield__label {
color: rgb(222, 50, 38);
font-size: 12px; }
.mdl-selectfield__label:after {
background-color: rgb(63,81,181);
bottom: 20px;
content: '';
height: 2px;
left: 45%;
position: absolute;
transition-duration: 0.2s;
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
visibility: hidden;
width: 10px; }
.mdl-selectfield.is-focused .mdl-selectfield__label:after {
left: 0;
visibility: visible;
width: 100%; }
.mdl-selectfield.is-invalid .mdl-selectfield__label:after {
background-color: rgb(222, 50, 38); }
.mdl-selectfield__error {
color: rgb(222, 50, 38);
position: absolute;
font-size: 12px;
margin-top: 3px;
visibility: hidden;
display: block; }
.mdl-selectfield.is-invalid .mdl-selectfield__error {
visibility: visible; }
.mdl-selectfield__icon {
bottom: 20px;
cursor: pointer;
color: rgba(0,0,0, 0.26);
padding: 4px 0;
position: absolute;
top: 20px;
right: 0;
pointer-events: none; }
.mdl-selectfield__icon > i {
outline: 0; }
.mdl-selectfield.is-dirty .mdl-selectfield__icon {
color: inherit; }
fieldset[disabled] .mdl-selectfield .mdl-selectfield__icon,
.mdl-selectfield.is-disabled.is-disabled .mdl-selectfield__icon {
color: rgba(0,0,0, 0.26); }
.mdl-selectfield--floating-label.is-invalid .mdl-selectfield__icon {
color: rgb(222, 50, 38); }

View File

@@ -0,0 +1,3 @@
.mdl-selectfield{position:relative;font-size:16px;display:inline-block;box-sizing:border-box;width:300px;max-width:100%;margin:0;padding:20px 0}.mdl-selectfield--align-right{text-align:right}.mdl-selectfield--full-width{width:100%}.mdl-selectfield__select{display:block;width:100%;padding:4px 0;margin:0;color:inherit;background:transparent;font-size:16px;text-align:left;border:none;border-bottom:1px solid rgba(0,0,0, 0.12);border-radius:0;-webkit-appearance:none;-moz-appearance:none;-ms-appearance:none;appearance:none}.mdl-selectfield__select::-ms-expand{display:none}.mdl-selectfield.is-focused .mdl-selectfield__select{outline:none}.mdl-selectfield.is-invalid .mdl-selectfield__select{border-color:rgb(222, 50, 38);box-shadow:none}fieldset[disabled] .mdl-selectfield .mdl-selectfield__select,.mdl-selectfield.is-disabled .mdl-selectfield__select{background-color:transparent;border-bottom:1px dotted rgba(0,0,0, 0.12);color:rgba(0,0,0, 0.26)}.mdl-selectfield__label{bottom:0;color:rgba(0,0,0, 0.26);font-size:16px;left:0;right:0;pointer-events:none;position:absolute;display:block;top:24px;width:100%;overflow:hidden;white-space:nowrap;text-align:left}.mdl-selectfield.is-dirty .mdl-selectfield__label{visibility:hidden}.mdl-selectfield--floating-label .mdl-selectfield__label{transition-duration:0.2s;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1)}fieldset[disabled] .mdl-selectfield .mdl-selectfield__label,.mdl-selectfield.is-disabled.is-disabled .mdl-selectfield__label{color:rgba(0,0,0, 0.26)}.mdl-selectfield--floating-label.is-focused .mdl-selectfield__label,.mdl-selectfield--floating-label.is-dirty .mdl-selectfield__label{color:rgb(63,81,181);font-size:12px;top:4px;visibility:visible}.mdl-selectfield--floating-label.is-invalid .mdl-selectfield__label{color:rgb(222, 50, 38);font-size:12px}.mdl-selectfield__label:after{background-color:rgb(63,81,181);bottom:20px;content:'';height:2px;left:45%;position:absolute;transition-duration:0.2s;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);visibility:hidden;width:10px}.mdl-selectfield.is-focused .mdl-selectfield__label:after{left:0;visibility:visible;width:100%}.mdl-selectfield.is-invalid .mdl-selectfield__label:after{background-color:rgb(222, 50, 38)}.mdl-selectfield__error{color:rgb(222, 50, 38);position:absolute;font-size:12px;margin-top:3px;visibility:hidden;display:block}.mdl-selectfield.is-invalid .mdl-selectfield__error{visibility:visible}.mdl-selectfield__icon{bottom:20px;cursor:pointer;color:rgba(0,0,0, 0.26);padding:4px 0;position:absolute;top:20px;right:0;pointer-events:none}.mdl-selectfield__icon>i{outline:0}.mdl-selectfield.is-dirty .mdl-selectfield__icon{color:inherit}fieldset[disabled] .mdl-selectfield .mdl-selectfield__icon,.mdl-selectfield.is-disabled.is-disabled .mdl-selectfield__icon{color:rgba(0,0,0, 0.26)}.mdl-selectfield--floating-label.is-invalid .mdl-selectfield__icon{color:rgb(222, 50, 38)}
/*# sourceMappingURL=mdl-selectfield.min.css.map */

View File

@@ -0,0 +1,8 @@
body {
padding: 50px;
font: 14px "Lucida Grande", Helvetica, Arial, sans-serif;
}
a {
color: #00B7FF;
}

9
routes/index.ts Normal file
View File

@@ -0,0 +1,9 @@
import * as express from "express";
const router = express.Router();
/* GET home page. */
router.get("/", (req, res, next) => {
res.render("index", { title: "Express" });
});
export = router;

9
routes/users.ts Normal file
View File

@@ -0,0 +1,9 @@
import * as express from "express";
const router = express.Router();
/* GET users listing. */
router.get("/", (req, res, next) => {
res.send("respond with a resource");
});
export = router;

10
tsconfig.json Normal file
View File

@@ -0,0 +1,10 @@
{
"compilerOptions": {
"module": "commonjs",
"target": "es5",
"sourceMap": true
},
"exclude": [
"node_modules"
]
}

29
tslint.json Normal file
View File

@@ -0,0 +1,29 @@
{
"extends": "tslint:recommended",
"rules": {
"max-line-length": {
"options": [120]
},
"new-parens": true,
"no-arg": true,
"no-bitwise": true,
"no-conditional-assignment": true,
"no-consecutive-blank-lines": false,
"no-console": {
"severity": "warning",
"options": [
"debug",
"info",
"log",
"time",
"timeEnd",
"trace"
]
}
},
"jsRules": {
"max-line-length": {
"options": [120]
}
}
}

6
views/error.pug Normal file
View File

@@ -0,0 +1,6 @@
extends layout
block content
h1= message
h2= error.status
pre #{error.stack}

159
views/index.pug Normal file
View File

@@ -0,0 +1,159 @@
extends layout
block content
style.
.demo-card-square.mdl-card {
width: 100%;
}
.demo-card-square > .mdl-card__title {
color: #fff;
background: #795548;
}
.mdl-selectfield__select option {
font-family: "Helvetica", "Arial", sans-serif;
}
script(src="https://cdn.jsdelivr.net/npm/@tensorflow/tfjs@0.13.3/dist/tf.min.js", defer)
script(src="/js/neuralnet.js", defer)
.mdl-grid
.mdl-cell--3-offset-desktop
.mdl-cell.mdl-cell--6-col.mdl-cell--12-col-tablet
.demo-card-square.mdl-card.mdl-shadow--2dp
.mdl-card__title.mdl-card--expand
h2.mdl-card__title-text Über diese Seite
.mdl-card__supporting-text
| Auf dieser Website kannst Du Deine Lieblingscocktails speichern und beim nächsten Mal wieder bestellen!
h3 Freiwillige Informationen
| Du kannst anonym Dein Alter und Geschlecht angeben, um die Cocktails weiter verbessern zu können.
.form
.mdl-textfield.mdl-js-textfield.mdl-textfield--floating-label.getmdl-select
input#sex-input.mdl-textfield__input(type='text', value='', readonly='')
input(type='hidden', value='', name='sex-input')
label.mdl-textfield__label(for='sex-input') Geschlecht
i.mdl-icon-toggle__label.material-icons keyboard_arrow_down
ul.mdl-menu.mdl-menu--bottom-left.mdl-js-menu(for='sex-input')
li.mdl-menu__item(data-val='na') Nicht angegeben
li.mdl-menu__item(data-val='m') Männlich
li.mdl-menu__item(data-val='w') Weiblich
li.mdl-menu__item(data-val='o') Divers
br
br
.mdl-textfield.mdl-js-textfield.mdl-textfield--floating-label
input.mdl-textfield__input(type="number", id="age_input")
label.mdl-textfield__label(for="age_input") Alter
br
br
br
br
br
br
br
//.mdl-card__actions.mdl-card--border
// a.mdl-button.mdl-button--colored.mdl-js-button.mdl-js-ripple-effect
// | View Updates
.mdl-grid
.mdl-cell--3-offset-desktop
.mdl-cell.mdl-cell--6-col.mdl-cell--12-col-tablet
.demo-card-square.mdl-card.mdl-shadow--2dp
.mdl-card__title.mdl-card--expand
h2.mdl-card__title-text Lieblingscocktails
.mdl-card__supporting-text
ul.demo-list-two.mdl-list
li.mdl-list__item.mdl-list__item--two-line
span.mdl-list__item-primary-content
i.material-icons.mdl-list__item-avatar local_bar
span Bryan Cranston
span.mdl-list__item-sub-title 62 Episodes, 62 Episodes, 62 Episodes, 62 Episodes, 62 Episodes, 62 Episodes, 62 Episodes
span.mdl-list__item-secondary-content
.mdl-grid(style="text-align:center;padding:0;margin:0")
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
a.mdl-list__item-secondary-action(href='#')
i.material-icons remove
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
#p1.mdl-progress.mdl-js-progress(style="width:100px;text-align:center")
span.mdl-list__item-secondary-info 6/7
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
a.mdl-list__item-secondary-action(href='#')
i.material-icons add
script.
document.querySelector('#p1').addEventListener('mdl-componentupgraded', function () {
this.MaterialProgress.setProgress(100 * 6 / 7);
});
li.mdl-list__item.mdl-list__item--two-line
span.mdl-list__item-primary-content
i.material-icons.mdl-list__item-avatar local_bar
span Aaron Paul
span.mdl-list__item-sub-title 62 Episodes
span.mdl-list__item-secondary-content
.mdl-grid(style="width:100px;text-align:center;padding:0;margin:0")
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
a.mdl-list__item-secondary-action(href='#')
i.material-icons remove
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
#p2.mdl-progress.mdl-js-progress(style="text-align:center")
span.mdl-list__item-secondary-info 2/7
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
a.mdl-list__item-secondary-action(href='#')
i.material-icons add
script.
document.querySelector('#p2').addEventListener('mdl-componentupgraded', function () {
this.MaterialProgress.setProgress(100 * 2 / 7);
});
li.mdl-list__item.mdl-list__item--two-line
span.mdl-list__item-primary-content
i.material-icons.mdl-list__item-avatar local_bar
span Bob Odenkirk
span.mdl-list__item-sub-title 62 Episodes
span.mdl-list__item-secondary-content
.mdl-grid(style="width:100px;text-align:center;padding:0;margin:0")
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
a.mdl-list__item-secondary-action(href='#')
i.material-icons remove
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
#p3.mdl-progress.mdl-js-progress(style="text-align:center")
span.mdl-list__item-secondary-info 5/7
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
a.mdl-list__item-secondary-action(href='#')
i.material-icons add
script.
document.querySelector('#p3').addEventListener('mdl-componentupgraded', function () {
this.MaterialProgress.setProgress(100 * 5 / 7);
});
br
.form
.mdl-grid
.mdl-cell--6-col
.mdl-selectfield.mdl-js-selectfield.mdl-selectfield--floating-label
select#gender.mdl-selectfield__select
option(value='')
option(value='1') Cocktail 1
option(value='2') Cocktail 2
option(value='3') Cocktail 3
option(value='4') Cocktail 4
option(value='5') Cocktail 5
label.mdl-selectfield__label(for='gender') New cocktail
span.mdl-selectfield__error Select a value
.mdl-cell--3-col
.mdl-grid(style="width:100px;text-align:center;padding:0;margin:0")
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
a.mdl-list__item-secondary-action(href='#')
i.material-icons remove
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
#pnew.mdl-progress.mdl-js-progress(style="text-align:center")
span.mdl-list__item-secondary-info 5/7
.mdl-cell(style="width:33.33333333%;margin-right:0px;margin-left:0px")
a.mdl-list__item-secondary-action(href='#')
i.material-icons add
script.
document.querySelector('#pnew').addEventListener('mdl-componentupgraded', function () {
this.MaterialProgress.setProgress(100 * 5 / 7);
});
.mdl-cell--3-col
button.mdl-button.mdl-js-button.mdl-button--fab.mdl-js-ripple-effect
i.material-icons add
//.mdl-card__actions.mdl-card--border
// a.mdl-button.mdl-button--colored.mdl-js-button.mdl-js-ripple-effect
// | View Updates

50
views/layout.pug Normal file
View File

@@ -0,0 +1,50 @@
doctype html
html
head
title= title
//link(rel = 'stylesheet', href = '/stylesheets/style.css')
link(rel = 'stylesheet', href = '/stylesheets/material.css')
link(rel = 'stylesheet', href = '/stylesheets/mdl-selectfield.min.css')
link(rel = 'stylesheet', href = '/stylesheets/getmdl-select.min.css')
link(rel = 'stylesheet', href = '/stylesheets/material-icons.css')
meta(name='viewport', content='width=device-width, initial-scale=1.0')
script(defer, type='text/javascript', src='/js/material.min.js')
script(defer, type='text/javascript', src='/js/mdl-selectfield.min.js')
script(defer, type='text/javascript', src='/js/getmdl-select.min.js')
body
style.
.demo-layout-transparent {
background: url('/images/transparent.jpg') center / cover;
}
.demo-layout-transparent .mdl-layout__header,
.demo-layout-transparent .mdl-layout__drawer-button {
/* This background is dark, so we set text to white. Use 87% black instead if
your background is light. */
color: white;
}
.demo-layout-transparent.mdl-layout.mdl-js-layout
header.mdl-layout__header.mdl-layout__header--transparent
.mdl-layout__header-row
// Title
span.mdl-layout-title= title
// Add spacer, to align navigation to the right
.mdl-layout-spacer
// Navigation
//nav.mdl-navigation
// a.mdl-navigation__link(href='') Link
// a.mdl-navigation__link(href='') Link
// a.mdl-navigation__link(href='') Link
// a.mdl-navigation__link(href='') Link
.mdl-layout__drawer
span.mdl-layout-title Kürbiskern
nav.mdl-navigation
a.mdl-navigation__link(href='/') Liste
a.mdl-navigation__link(href='/recommends') Empfohlene Cocktails
a.mdl-navigation__link(href='/similar') Ähnliche Cocktails
a.mdl-navigation__link(href='/admin') Admin
a.mdl-navigation__link(href='/impressum') Impressum & Datenschutz
main.mdl-layout__content
block content