From 40a59f6413c279bd8fcae24717dee2b01217a633 Mon Sep 17 00:00:00 2001 From: lduboeuf Date: Mon, 19 Dec 2016 12:19:13 +0100 Subject: [PATCH] publish to gh-pages site --- dist/dev/index.html | 39 --------------------- dist/dev/scripts/scripts.js | 1 - dist/dev/scripts/vendors.js | 1 - dist/dev/styles/main.css | 1 - dist/dev/templates/about.html | 1 - dist/dev/templates/archive-details.html | 1 - dist/dev/templates/archive-list.html | 1 - dist/dev/templates/archive-save.html | 1 - dist/dev/templates/home.html | 1 - dist/dev/templates/team-add.html | 1 - dist/dev/templates/team-list-details.html | 1 - dist/dev/templates/team-list.html | 1 - dist/dev/templates/team-member-add.html | 1 - dist/dev/templates/team-member-details.html | 1 - dist/index.html | 2 ++ dist/templates/about.html | 2 +- 16 files changed, 3 insertions(+), 53 deletions(-) delete mode 100644 dist/dev/index.html delete mode 100644 dist/dev/scripts/scripts.js delete mode 100644 dist/dev/scripts/vendors.js delete mode 100644 dist/dev/styles/main.css delete mode 100644 dist/dev/templates/about.html delete mode 100644 dist/dev/templates/archive-details.html delete mode 100644 dist/dev/templates/archive-list.html delete mode 100644 dist/dev/templates/archive-save.html delete mode 100644 dist/dev/templates/home.html delete mode 100644 dist/dev/templates/team-add.html delete mode 100644 dist/dev/templates/team-list-details.html delete mode 100644 dist/dev/templates/team-list.html delete mode 100644 dist/dev/templates/team-member-add.html delete mode 100644 dist/dev/templates/team-member-details.html diff --git a/dist/dev/index.html b/dist/dev/index.html deleted file mode 100644 index f42de16..0000000 --- a/dist/dev/index.html +++ /dev/null @@ -1,39 +0,0 @@ -Team Tool Box
Team Tool Box Build your teams randomly!
×

\ No newline at end of file diff --git a/dist/dev/scripts/scripts.js b/dist/dev/scripts/scripts.js deleted file mode 100644 index 79dd3f7..0000000 --- a/dist/dev/scripts/scripts.js +++ /dev/null @@ -1 +0,0 @@ -!function(){function a(a,b){b=b||{bubbles:!1,cancelable:!1,detail:void 0};var c=document.createEvent("CustomEvent");return c.initCustomEvent(a,b.bubbles,b.cancelable,b.detail),c}a.prototype=window.Event.prototype,window.CustomEvent=a}(),function(a){function b(a,b){var c=document.querySelector("section#"+a);if(0==c.length)return void console.warn("section with id=%s not found!",a);var d=e[a];if(d){var j=c.length>0?c[0]:null,k=d.call(j,b);"function"==typeof k&&(i(c,"[no-ctl-cache]")||(e[a]=k),k.call(j,b))}if(f&&(document.body.classList.remove(f),h&&(document.dispatchEvent(new CustomEvent("page.hidden",{currentPage:f})),h.getAttribute("src")&&i(h,"[no-ctl-cache]")&&(h.innerHTML=null))),g=f,document.body.classList.add(f=a),(h=c)&&(document.dispatchEvent(new CustomEvent("page.shown",{currentPage:f})),""!=c.getAttribute("default"))){var l="#"+f;b&&(l+=":"+b),""!=location.hash&&location.hash===l||history.pushState(null,null,"#"+a)}}function c(a,d){var e=document.body.querySelector("section#"+a),f=e.getAttribute("src");f&&!e.hasChildNodes()?c.get(f,e,a,d):b(a,d)}function d(){var a=location.hash||"#"+document.querySelector("section[default]").getAttribute("id"),b=/#([-0-9A-Za-z]+)(\:(.+))?/,d=b.exec(a);a=d[1];var e=d[3];c(a,e)}var e={},f=null,g=null,h=null,i=function(a,b){return(a.matches||a.matchesSelector||a.msMatchesSelector||a.mozMatchesSelector||a.webkitMatchesSelector||a.oMatchesSelector).call(a,b)};c.back=function(a){c(g,a)},c.page=function(a,b){e[a]=b},c.get=function(a,c,d,e){var f=new XMLHttpRequest;f.open("GET",a,!0),f.onload=function(){f.status>=200&&f.status<400?(c.innerHTML=f.responseText,b(d,e)):console.warn("failed to get %s page!",d)},f.onerror=function(){console.warn("failed to get %s page!",d)},f.send()},c.start=function(){a.dispatchEvent(new CustomEvent("hashchange"))},a.addEventListener("hashchange",d),a.app=c}(this),function(a){function b(a,b){var c=JSON.stringify(b,a.fields);localStorage.setItem(a.name,c)}function c(a){var b=localStorage.getItem(a);return JSON.parse(b)}function d(a,b){if(!a)return null;for(var c=0;c0){var j=c.map(function(a,c){return b[a]}),i={name:"Team Orphan(s)",members:j};g.push(i)}return g},m=function(a){i=a,e.innerHTML=h(a);var b=e.querySelector("button");b.onclick=function(){i&&app("archive-save",i)}};return e.innerHTML=null,f.onclick=function(a){a.preventDefault(),j()},function(a){console.log("kikou");var b=TeamRepository.findAll();if(0==b.length&&app.alert("alert-info",'hello, no members found, you can add members by clicking on the "Team List" menu'),d.innerHTML=g(b),a&&"onSavedOutput"==a.event){var c=e.querySelector("button");c.classList.toggle("btn-success"),c.onclick=null}}}),app.page("team-member-details",function(){var a=document.querySelector("#team-member-details form"),b=a.querySelector('[name="id"]'),c=a.querySelector('[name="name"]'),d=a.querySelector('input[name="update-member"]'),e=a.querySelector('input[name="remove-member"]'),f=null;return d.onclick=function(a){a.preventDefault(),f.name=c.value,TeamRepository.save(),history.back()},e.onclick=function(a){a.preventDefault();var d=window.confirm("are you sure you want to remove "+c.value);d&&(TeamRepository.removeMember(b.value),TeamRepository.save(),history.back())},function(a){var d=a;f=TeamRepository.findMember(d),b.value=f.id,c.value=f.name}}),app.page("team-member-add",function(){var a=document.querySelector('#team-member-add form input[name="name"]'),b=document.querySelector('#team-member-add form input[name="add"]'),c=null;return b.onclick=function(b){b.preventDefault(),a.value.length>0&&(TeamRepository.addMember(c,{name:a.value}),history.back())},function(b){c=b,a.value=""}}),app.page("team-add",function(){var a=document.querySelector('#team-add form input[name="name"]'),b=document.querySelector('#team-add form input[name="add"]');return b.onclick=function(b){b.preventDefault(),a.value.length>0&&(TeamRepository.addTeam({name:a.value}),history.back())},function(b){a.value=""}}),app.page("archive-save",function(){var a,b=document.querySelector("#archive-save form"),c=b.querySelector('input[name="name"]'),d=b.querySelector('textarea[name="description"]'),e=b.querySelector(".button"),f=document.querySelector("#archive-save .team-list"),g=doT.template(f.innerHTML);return e.onclick=function(b){if(b.preventDefault(),0==c.value.length)return!1;var e={name:c.value,description:d.value,teams:a};TeamRepository.addArchive(e),alert("cool, generated teams archived"),app.back({event:"onSavedOutput"})},function(b){a=b,f.innerHTML=g(a),c.value="",d.value=""}}),app.page("archive-list",function(){var a=document.querySelector("#archive-list .archive-list"),b=doT.template(a.innerHTML);return a.innerHTML=null,function(c){var d=TeamRepository.findArchives();a.innerHTML=b(d)}}),app.page("archive-details",function(){var a=document.getElementById("archive-details"),b=doT.template(a.innerHTML),c=null;a.innerHTML=null;var d=function(){return confirm("sure you want to remove this archive ?")&&(TeamRepository.removeArchive(c),history.back()),!1};return function(e){c=e;var f=TeamRepository.findArchive(c);a.innerHTML=b(f),a.querySelector(".remove-link").onclick=d}}); \ No newline at end of file diff --git a/dist/dev/scripts/vendors.js b/dist/dev/scripts/vendors.js deleted file mode 100644 index 6c9f8f3..0000000 --- a/dist/dev/scripts/vendors.js +++ /dev/null @@ -1 +0,0 @@ -!function(){"use strict";function a(b,c,d){return("string"==typeof c?c:c.toString()).replace(b.define||f,function(a,c,e,f){return 0===c.indexOf("def.")&&(c=c.substring(4)),c in d||(":"===e?(b.defineParams&&f.replace(b.defineParams,function(a,b,e){d[c]={arg:b,text:e}}),c in d||(d[c]=f)):new Function("def","def['"+c+"']="+f)(d)),""}).replace(b.use||f,function(c,e){b.useParams&&(e=e.replace(b.useParams,function(a,b,c,e){if(d[c]&&d[c].arg&&e){var f=(c+":"+e).replace(/'|\\/g,"_");return d.__exp=d.__exp||{},d.__exp[f]=d[c].text.replace(new RegExp("(^|[^\\w$])"+d[c].arg+"([^\\w$])","g"),"$1"+e+"$2"),b+"def.__exp['"+f+"']"}}));var f=new Function("def","return "+e)(d);return f?a(b,f,d):f})}function b(a){return a.replace(/\\('|\\)/g,"$1").replace(/[\r\t\n]/g," ")}var c,d={version:"1.1.1",templateSettings:{evaluate:/\{\{([\s\S]+?(\}?)+)\}\}/g,interpolate:/\{\{=([\s\S]+?)\}\}/g,encode:/\{\{!([\s\S]+?)\}\}/g,use:/\{\{#([\s\S]+?)\}\}/g,useParams:/(^|[^\w$])def(?:\.|\[[\'\"])([\w$\.]+)(?:[\'\"]\])?\s*\:\s*([\w$\.]+|\"[^\"]+\"|\'[^\']+\'|\{[^\}]+\})/g,define:/\{\{##\s*([\w\.$]+)\s*(\:|=)([\s\S]+?)#\}\}/g,defineParams:/^\s*([\w$]+):([\s\S]+)/,conditional:/\{\{\?(\?)?\s*([\s\S]*?)\s*\}\}/g,iterate:/\{\{~\s*(?:\}\}|([\s\S]+?)\s*\:\s*([\w$]+)\s*(?:\:\s*([\w$]+))?\s*\}\})/g,varname:"it",strip:!0,append:!0,selfcontained:!1,doNotSkipEncoded:!1},template:void 0,compile:void 0,log:!0};d.encodeHTMLSource=function(a){var b={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"},c=a?/[&<>"'\/]/g:/&(?!#?\w+;)|<|>|"|'|\//g;return function(a){return a?a.toString().replace(c,function(a){return b[a]||a}):""}},c=function(){return this||(0,eval)("this")}(),"undefined"!=typeof module&&module.exports?module.exports=d:"function"==typeof define&&define.amd?define(function(){return d}):c.doT=d;var e={append:{start:"'+(",end:")+'",startencode:"'+encodeHTML("},split:{start:"';out+=(",end:");out+='",startencode:"';out+=encodeHTML("}},f=/$^/;d.template=function(g,h,i){h=h||d.templateSettings;var j,k,l=h.append?e.append:e.split,m=0,n=h.use||h.define?a(h,g,i||{}):g;n=("var out='"+(h.strip?n.replace(/(^|\r|\n)\t* +| +\t*(\r|\n|$)/g," ").replace(/\r|\n|\t|\/\*[\s\S]*?\*\//g,""):n).replace(/'|\\/g,"\\$&").replace(h.interpolate||f,function(a,c){return l.start+b(c)+l.end}).replace(h.encode||f,function(a,c){return j=!0,l.startencode+b(c)+l.end}).replace(h.conditional||f,function(a,c,d){return c?d?"';}else if("+b(d)+"){out+='":"';}else{out+='":d?"';if("+b(d)+"){out+='":"';}out+='"}).replace(h.iterate||f,function(a,c,d,e){return c?(m+=1,k=e||"i"+m,c=b(c),"';var arr"+m+"="+c+";if(arr"+m+"){var "+d+","+k+"=-1,l"+m+"=arr"+m+".length-1;while("+k+"section{margin:1em;display:none}.brand span,body.about>section#about,body.archive-details>section#archive-details,body.archive-list>section#archive-list,body.archive-save>section#archive-save,body.home>section#home,body.team-add>section#team-add,body.team-list-details>section#team-list-details,body.team-list>section#team-list,body.team-member-add>section#team-member-add,body.team-member-details>section#team-member-details{display:block}body.about #menu a[href="#about"],body.archive-details #menu a[href="#archive-list "],body.archive-list #menu a[href="#archive-list "],body.archive-save #menu a[href="#archive-list "],body.home #menu a[href="#home"],body.team-add #menu a[href="#team-list"],body.team-list #menu a[href="#team-list"],body.team-list-details #menu a[href="#team-list"],body.team-member-add #menu a[href="#team-list"],body.team-member-details #menu a[href="#team-list"]{background-color:#555}body>header,ul.topnav{background-color:#333}body>header{color:#f2f2f2;box-shadow:0 5px 8px #ccc;top:0;width:100%}table td{padding:0}a{text-decoration:none;color:#4078c0}.brand a,ul.topnav li a{color:#f2f2f2;text-decoration:none}body .brand{padding:14px 12px;text-align:left}#archive-save .team-list{font-size:.7em}ul.topnav{text-align:right;margin:0;padding:0;overflow:hidden}ul.topnav li{display:inline}ul.topnav li a{display:inline-block;text-align:center;padding:14px 16px;transition:.3s}ul.topnav li a.selected,ul.topnav li a:hover{background-color:#555}ul.topnav li.icon{display:none}@media screen and (max-width:680px){ul.topnav{position:absolute;right:0;top:0}ul.topnav li{display:none}ul.topnav li.icon{float:right;display:inline-block}ul.topnav.responsive,ul.topnav.responsive li.icon{position:absolute;right:0;top:0}ul.topnav.responsive{padding-right:30px}ul.topnav.responsive li{float:none;display:inline}ul.topnav.responsive li a{display:block;text-align:left}}.link-home{color:#000;text-decoration:none;padding-right:12px}.alert-info{margin:10px;display:none;background-color:#D9EDF7;color:#31708f;border:1px solid #31708f;border-radius:4px}#home form,select{background-color:#fff}.alert-closebtn{margin:2px;text-decoration:none;float:right;font-size:1.2em;color:inherit}.alert-closebtn:hover{cursor:pointer;color:#000}.alert-msg{padding:16px}#home form{border:1px solid #dbdbdb;border-radius:4px;padding:8px;box-shadow:1px 1px 0 #dbdbdb}#teams-result div{padding-top:12px}section header{display:flex;justify-content:space-between}.radio-group,select{display:inline-block}select{padding:7px;border:1px solid #D1D1D1;border-radius:4px;box-shadow:none;font-size:.9em}input[type=email],input[type=password],input[type=tel],input[type=text],input[type=url]{color:#5f5f5f;box-sizing:border-box;box-shadow:1px 2px 4px 0 rgba(0,0,0,.08);padding:8px;border:1px solid #dbdbdb}.btn-danger{background-color:#D9534F}.btn-default{background-color:#337AB7}.btn-success{background-color:#5CB85C}button,input[type=button],input[type=submit]{display:inline-block;margin-top:12px;border-radius:2px;color:#fff;font-weight:700;box-shadow:1px 2px 4px 0 rgba(0,0,0,.08);padding:8px 12px;border:0}button,input[type=button]:hover,input[type=submit]{cursor:pointer}.radio-group{margin:0;padding:7px;font-size:.9em}textarea{color:#5f5f5f;width:50%;height:80px;box-shadow:1px 2px 4px 0 rgba(0,0,0,.08);font:400 13px sans-serif;border:1px solid #dbdbdb;resize:vertical;display:block}@media screen and (max-width:680px){button,form,input,select,textarea{width:100%}input[type=radio]{width:auto}.radio-group{display:block}}section header{margin-bottom:20px;padding:0}.header-tbl,div.team h3{margin:0;padding:12px;background-color:#F0F0F0;border:1px solid #ddd;border-bottom:0;font-weight:700}section ul{margin:0;padding:0;border:1px solid #ddd;background-color:#fff}section ul li{padding:8px 16px;border-bottom:1px solid #ddd}section ul li a{display:block;text-decoration:none;color:#4078c0}section ul li:hover{background-color:#fcfcfc}section ul li:last-child{border-bottom:none} \ No newline at end of file diff --git a/dist/dev/templates/about.html b/dist/dev/templates/about.html deleted file mode 100644 index 13dadb4..0000000 --- a/dist/dev/templates/about.html +++ /dev/null @@ -1 +0,0 @@ -

Welcome to Team Tool Box, a project to help you build teams or find members randomly!

All datas are for instance stored in your browser local storage

Developper: This is a sample Single Page Application built with several tiny components, more information and source code here: https://github.com/lduboeuf/team-tool-box

Also,demonstrate that for little apps, there is no need to big MV* Frameworks and complex glue code.

\ No newline at end of file diff --git a/dist/dev/templates/archive-details.html b/dist/dev/templates/archive-details.html deleted file mode 100644 index 1dd9fb7..0000000 --- a/dist/dev/templates/archive-details.html +++ /dev/null @@ -1 +0,0 @@ -

Archive "{{=it.name}}"

description:

{{=it.description}}

{{~it.teams :team:idx}}

{{=team.name}}

    {{~team.members :member:idxm}}
  • {{=member.name}}
  • {{~}}
{{~}}
\ No newline at end of file diff --git a/dist/dev/templates/archive-list.html b/dist/dev/templates/archive-list.html deleted file mode 100644 index c7d49e0..0000000 --- a/dist/dev/templates/archive-list.html +++ /dev/null @@ -1 +0,0 @@ -

Archive List

\ No newline at end of file diff --git a/dist/dev/templates/archive-save.html b/dist/dev/templates/archive-save.html deleted file mode 100644 index 847779f..0000000 --- a/dist/dev/templates/archive-save.html +++ /dev/null @@ -1 +0,0 @@ -

Save output


{{~it :team:idx}}

{{=team.name}}

    {{~team.members :member:idxm}}
  • {{=member.name}}
  • {{~}}
{{~}}
\ No newline at end of file diff --git a/dist/dev/templates/home.html b/dist/dev/templates/home.html deleted file mode 100644 index 63216df..0000000 --- a/dist/dev/templates/home.html +++ /dev/null @@ -1 +0,0 @@ -

{{~it :team:idx}}

{{=team.name}}

    {{~team.members :member:idxm}}
  • {{=member.name}}
  • {{~}}
{{~}}
\ No newline at end of file diff --git a/dist/dev/templates/team-add.html b/dist/dev/templates/team-add.html deleted file mode 100644 index 2a744b2..0000000 --- a/dist/dev/templates/team-add.html +++ /dev/null @@ -1 +0,0 @@ -

Add a team

\ No newline at end of file diff --git a/dist/dev/templates/team-list-details.html b/dist/dev/templates/team-list-details.html deleted file mode 100644 index 934d967..0000000 --- a/dist/dev/templates/team-list-details.html +++ /dev/null @@ -1 +0,0 @@ -

Team "{{=it.name}}"

\ No newline at end of file diff --git a/dist/dev/templates/team-list.html b/dist/dev/templates/team-list.html deleted file mode 100644 index 5a52738..0000000 --- a/dist/dev/templates/team-list.html +++ /dev/null @@ -1 +0,0 @@ -

Team list

\ No newline at end of file diff --git a/dist/dev/templates/team-member-add.html b/dist/dev/templates/team-member-add.html deleted file mode 100644 index ab4c2f9..0000000 --- a/dist/dev/templates/team-member-add.html +++ /dev/null @@ -1 +0,0 @@ -

Add a member

\ No newline at end of file diff --git a/dist/dev/templates/team-member-details.html b/dist/dev/templates/team-member-details.html deleted file mode 100644 index 0c45aac..0000000 --- a/dist/dev/templates/team-member-details.html +++ /dev/null @@ -1 +0,0 @@ -

Member Details

\ No newline at end of file diff --git a/dist/index.html b/dist/index.html index 18f809c..99fdb2b 100644 --- a/dist/index.html +++ b/dist/index.html @@ -33,5 +33,7 @@ } document.querySelector('div.brand a').onclick = setSelected; + app.start(); + //document.writeln(localStorage.getItem('ttb')); \ No newline at end of file diff --git a/dist/templates/about.html b/dist/templates/about.html index 2b70662..13dadb4 100644 --- a/dist/templates/about.html +++ b/dist/templates/about.html @@ -1 +1 @@ -

Welcome to Team Tool Box, a project to help you build teams or find members randomly (or pseudo-randomly for purist)!

All datas are for instance stored in your browser local storage

Developper: This is a sample Single Page Application built with several tiny components, more information and source code here: https://github.com/lduboeuf/team-tool-box

Also,demonstrate that for little apps, there is no need to big MV* Frameworks and complex glue code.

\ No newline at end of file +

Welcome to Team Tool Box, a project to help you build teams or find members randomly!

All datas are for instance stored in your browser local storage

Developper: This is a sample Single Page Application built with several tiny components, more information and source code here: https://github.com/lduboeuf/team-tool-box

Also,demonstrate that for little apps, there is no need to big MV* Frameworks and complex glue code.

\ No newline at end of file