";
- return div.innerHTML.indexOf('
') > 0
-}
-
-// #3663: IE encodes newlines inside attribute values while other browsers don't
-var shouldDecodeNewlines = inBrowser ? getShouldDecode(false) : false;
-// #6828: chrome encodes content in a[href]
-var shouldDecodeNewlinesForHref = inBrowser ? getShouldDecode(true) : false;
-
-/* */
-
-var idToTemplate = cached(function (id) {
- var el = query(id);
- return el && el.innerHTML
-});
-
-var mount = Vue.prototype.$mount;
-Vue.prototype.$mount = function (
- el,
- hydrating
-) {
- el = el && query(el);
-
- /* istanbul ignore if */
- if (el === document.body || el === document.documentElement) {
- "development" !== 'production' && warn(
- "Do not mount Vue to or - mount to normal elements instead."
- );
- return this
- }
-
- var options = this.$options;
- // resolve template/el and convert to render function
- if (!options.render) {
- var template = options.template;
- if (template) {
- if (typeof template === 'string') {
- if (template.charAt(0) === '#') {
- template = idToTemplate(template);
- /* istanbul ignore if */
- if ("development" !== 'production' && !template) {
- warn(
- ("Template element not found or is empty: " + (options.template)),
- this
- );
- }
- }
- } else if (template.nodeType) {
- template = template.innerHTML;
- } else {
- {
- warn('invalid template option:' + template, this);
- }
- return this
- }
- } else if (el) {
- template = getOuterHTML(el);
- }
- if (template) {
- /* istanbul ignore if */
- if ("development" !== 'production' && config.performance && mark) {
- mark('compile');
- }
-
- var ref = compileToFunctions(template, {
- shouldDecodeNewlines: shouldDecodeNewlines,
- shouldDecodeNewlinesForHref: shouldDecodeNewlinesForHref,
- delimiters: options.delimiters,
- comments: options.comments
- }, this);
- var render = ref.render;
- var staticRenderFns = ref.staticRenderFns;
- options.render = render;
- options.staticRenderFns = staticRenderFns;
-
- /* istanbul ignore if */
- if ("development" !== 'production' && config.performance && mark) {
- mark('compile end');
- measure(("vue " + (this._name) + " compile"), 'compile', 'compile end');
- }
- }
- }
- return mount.call(this, el, hydrating)
-};
-
-/**
- * Get outerHTML of elements, taking care
- * of SVG elements in IE as well.
- */
-function getOuterHTML (el) {
- if (el.outerHTML) {
- return el.outerHTML
- } else {
- var container = document.createElement('div');
- container.appendChild(el.cloneNode(true));
- return container.innerHTML
- }
-}
-
-Vue.compile = compileToFunctions;
-
-return Vue;
-
-})));
diff --git a/dist/dependencias/vuerouter.min.js b/dist/dependencias/vuerouter.min.js
deleted file mode 100644
index 555b88e..0000000
--- a/dist/dependencias/vuerouter.min.js
+++ /dev/null
@@ -1 +0,0 @@
-!function(global,factory){"object"==typeof exports&&"undefined"!=typeof module?module.exports=factory():"function"==typeof define&&define.amd?define(factory):global.VueRouter=factory()}(this,function(){"use strict";function assert(condition,message){if(!condition)throw new Error("[vue-router] "+message)}function warn(condition,message){condition||"undefined"!=typeof console&&console.warn("[vue-router] "+message)}function isError(err){return Object.prototype.toString.call(err).indexOf("Error")>-1}var View={name:"router-view",functional:!0,props:{name:{type:String,default:"default"}},render:function(_,ref){var props=ref.props,children=ref.children,parent=ref.parent,data=ref.data;data.routerView=!0;for(var h=parent.$createElement,name=props.name,route=parent.$route,cache=parent._routerViewCache||(parent._routerViewCache={}),depth=0,inactive=!1;parent&&parent._routerRoot!==parent;)parent.$vnode&&parent.$vnode.data.routerView&&depth++,parent._inactive&&(inactive=!0),parent=parent.$parent;if(data.routerViewDepth=depth,inactive)return h(cache[name],data,children);var matched=route.matched[depth];if(!matched)return cache[name]=null,h();var component=cache[name]=matched.components[name];data.registerRouteInstance=function(vm,val){var current=matched.instances[name];(val&¤t!==vm||!val&¤t===vm)&&(matched.instances[name]=val)},(data.hook||(data.hook={})).prepatch=function(_,vnode){matched.instances[name]=vnode.componentInstance};var propsToPass=data.props=function(route,config){switch(typeof config){case"undefined":return;case"object":return config;case"function":return config(route);case"boolean":return config?route.params:void 0;default:warn(!1,'props in "'+route.path+'" is a '+typeof config+", expecting an object, function or boolean.")}}(route,matched.props&&matched.props[name]);if(propsToPass){propsToPass=data.props=function(to,from){for(var key in from)to[key]=from[key];return to}({},propsToPass);var attrs=data.attrs=data.attrs||{};for(var key in propsToPass)component.props&&key in component.props||(attrs[key]=propsToPass[key],delete propsToPass[key])}return h(component,data,children)}};var encodeReserveRE=/[!'()*]/g,encodeReserveReplacer=function(c){return"%"+c.charCodeAt(0).toString(16)},commaRE=/%2C/g,encode=function(str){return encodeURIComponent(str).replace(encodeReserveRE,encodeReserveReplacer).replace(commaRE,",")},decode=decodeURIComponent;function parseQuery(query){var res={};return(query=query.trim().replace(/^(\?|#|&)/,""))?(query.split("&").forEach(function(param){var parts=param.replace(/\+/g," ").split("="),key=decode(parts.shift()),val=parts.length>0?decode(parts.join("=")):null;void 0===res[key]?res[key]=val:Array.isArray(res[key])?res[key].push(val):res[key]=[res[key],val]}),res):res}function stringifyQuery(obj){var res=obj?Object.keys(obj).map(function(key){var val=obj[key];if(void 0===val)return"";if(null===val)return encode(key);if(Array.isArray(val)){var result=[];return val.forEach(function(val2){void 0!==val2&&(null===val2?result.push(encode(key)):result.push(encode(key)+"="+encode(val2)))}),result.join("&")}return encode(key)+"="+encode(val)}).filter(function(x){return x.length>0}).join("&"):null;return res?"?"+res:""}var trailingSlashRE=/\/?$/;function createRoute(record,location,redirectedFrom,router){var stringifyQuery$$1=router&&router.options.stringifyQuery,query=location.query||{};try{query=clone(query)}catch(e){}var route={name:location.name||record&&record.name,meta:record&&record.meta||{},path:location.path||"/",hash:location.hash||"",query:query,params:location.params||{},fullPath:getFullPath(location,stringifyQuery$$1),matched:record?function(record){var res=[];for(;record;)res.unshift(record),record=record.parent;return res}(record):[]};return redirectedFrom&&(route.redirectedFrom=getFullPath(redirectedFrom,stringifyQuery$$1)),Object.freeze(route)}function clone(value){if(Array.isArray(value))return value.map(clone);if(value&&"object"==typeof value){var res={};for(var key in value)res[key]=clone(value[key]);return res}return value}var START=createRoute(null,{path:"/"});function getFullPath(ref,_stringifyQuery){var path=ref.path,query=ref.query;void 0===query&&(query={});var hash=ref.hash;return void 0===hash&&(hash=""),(path||"/")+(_stringifyQuery||stringifyQuery)(query)+hash}function isSameRoute(a,b){return b===START?a===b:!!b&&(a.path&&b.path?a.path.replace(trailingSlashRE,"")===b.path.replace(trailingSlashRE,"")&&a.hash===b.hash&&isObjectEqual(a.query,b.query):!(!a.name||!b.name)&&(a.name===b.name&&a.hash===b.hash&&isObjectEqual(a.query,b.query)&&isObjectEqual(a.params,b.params)))}function isObjectEqual(a,b){if(void 0===a&&(a={}),void 0===b&&(b={}),!a||!b)return a===b;var aKeys=Object.keys(a),bKeys=Object.keys(b);return aKeys.length===bKeys.length&&aKeys.every(function(key){var aVal=a[key],bVal=b[key];return"object"==typeof aVal&&"object"==typeof bVal?isObjectEqual(aVal,bVal):String(aVal)===String(bVal)})}var _Vue,toTypes=[String,Object],eventTypes=[String,Array],Link={name:"router-link",props:{to:{type:toTypes,required:!0},tag:{type:String,default:"a"},exact:Boolean,append:Boolean,replace:Boolean,activeClass:String,exactActiveClass:String,event:{type:eventTypes,default:"click"}},render:function(h){var this$1=this,router=this.$router,current=this.$route,ref=router.resolve(this.to,current,this.append),location=ref.location,route=ref.route,href=ref.href,classes={},globalActiveClass=router.options.linkActiveClass,globalExactActiveClass=router.options.linkExactActiveClass,activeClassFallback=null==globalActiveClass?"router-link-active":globalActiveClass,exactActiveClassFallback=null==globalExactActiveClass?"router-link-exact-active":globalExactActiveClass,activeClass=null==this.activeClass?activeClassFallback:this.activeClass,exactActiveClass=null==this.exactActiveClass?exactActiveClassFallback:this.exactActiveClass,compareTarget=location.path?createRoute(null,location,null,router):route;classes[exactActiveClass]=isSameRoute(current,compareTarget),classes[activeClass]=this.exact?classes[exactActiveClass]:function(current,target){return 0===current.path.replace(trailingSlashRE,"/").indexOf(target.path.replace(trailingSlashRE,"/"))&&(!target.hash||current.hash===target.hash)&&function(current,target){for(var key in target)if(!(key in current))return!1;return!0}(current.query,target.query)}(current,compareTarget);var handler=function(e){guardEvent(e)&&(this$1.replace?router.replace(location):router.push(location))},on={click:guardEvent};Array.isArray(this.event)?this.event.forEach(function(e){on[e]=handler}):on[this.event]=handler;var data={class:classes};if("a"===this.tag)data.on=on,data.attrs={href:href};else{var a=function findAnchor(children){if(children)for(var child,i=0;i
=0&&(hash=path.slice(hashIndex),path=path.slice(0,hashIndex));var queryIndex=path.indexOf("?");return queryIndex>=0&&(query=path.slice(queryIndex+1),path=path.slice(0,queryIndex)),{path:path,query:query,hash:hash}}(next.path||""),basePath=current&¤t.path||"/",path=parsedPath.path?resolvePath(parsedPath.path,basePath,append||next.append):basePath,query=function(query,extraQuery,_parseQuery){void 0===extraQuery&&(extraQuery={});var parsedQuery,parse=_parseQuery||parseQuery;try{parsedQuery=parse(query||"")}catch(e){warn(!1,e.message),parsedQuery={}}for(var key in extraQuery)parsedQuery[key]=extraQuery[key];return parsedQuery}(parsedPath.query,next.query,router&&router.options.parseQuery),hash=next.hash||parsedPath.hash;return hash&&"#"!==hash.charAt(0)&&(hash="#"+hash),{_normalized:!0,path:path,query:query,hash:hash}}function assign(a,b){for(var key in b)a[key]=b[key];return a}function createMatcher(routes,router){var ref=createRouteMap(routes),pathList=ref.pathList,pathMap=ref.pathMap,nameMap=ref.nameMap;function match(raw,currentRoute,redirectedFrom){var location=normalizeLocation(raw,currentRoute,!1,router),name=location.name;if(name){var record=nameMap[name];if(warn(record,"Route with name '"+name+"' does not exist"),!record)return _createRoute(null,location);var paramNames=record.regex.keys.filter(function(key){return!key.optional}).map(function(key){return key.name});if("object"!=typeof location.params&&(location.params={}),currentRoute&&"object"==typeof currentRoute.params)for(var key in currentRoute.params)!(key in location.params)&¶mNames.indexOf(key)>-1&&(location.params[key]=currentRoute.params[key]);if(record)return location.path=fillParams(record.path,location.params,'named route "'+name+'"'),_createRoute(record,location,redirectedFrom)}else if(location.path){location.params={};for(var i=0;i=queue.length?cb():queue[index]?fn(queue[index],function(){step(index+1)}):step(index+1)};step(0)}function resolveAsyncComponents(matched){return function(to,from,next){var hasAsync=!1,pending=0,error=null;flatMapComponents(matched,function(def,_,match,key){if("function"==typeof def&&void 0===def.cid){hasAsync=!0,pending++;var res,resolve=once(function(resolvedDef){var obj;((obj=resolvedDef).__esModule||hasSymbol&&"Module"===obj[Symbol.toStringTag])&&(resolvedDef=resolvedDef.default),def.resolved="function"==typeof resolvedDef?resolvedDef:_Vue.extend(resolvedDef),match.components[key]=resolvedDef,--pending<=0&&next()}),reject=once(function(reason){var msg="Failed to resolve async component "+key+": "+reason;warn(!1,msg),error||(error=isError(reason)?reason:new Error(msg),next(error))});try{res=def(resolve,reject)}catch(e){reject(e)}if(res)if("function"==typeof res.then)res.then(resolve,reject);else{var comp=res.component;comp&&"function"==typeof comp.then&&comp.then(resolve,reject)}}}),hasAsync||next()}}function flatMapComponents(matched,fn){return flatten(matched.map(function(m){return Object.keys(m.components).map(function(key){return fn(m.components[key],m.instances[key],m,key)})}))}function flatten(arr){return Array.prototype.concat.apply([],arr)}var hasSymbol="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag;function once(fn){var called=!1;return function(){for(var args=[],len=arguments.length;len--;)args[len]=arguments[len];if(!called)return called=!0,fn.apply(this,args)}}var History=function(router,base){this.router=router,this.base=function(base){if(!base)if(inBrowser){var baseEl=document.querySelector("base");base=(base=baseEl&&baseEl.getAttribute("href")||"/").replace(/^https?:\/\/[^\/]+/,"")}else base="/";"/"!==base.charAt(0)&&(base="/"+base);return base.replace(/\/$/,"")}(base),this.current=START,this.pending=null,this.ready=!1,this.readyCbs=[],this.readyErrorCbs=[],this.errorCbs=[]};function extractGuards(records,name,bind,reverse){var guards=flatMapComponents(records,function(def,instance,match,key){var guard=function(def,key){"function"!=typeof def&&(def=_Vue.extend(def));return def.options[key]}(def,name);if(guard)return Array.isArray(guard)?guard.map(function(guard){return bind(guard,instance,match,key)}):bind(guard,instance,match,key)});return flatten(reverse?guards.reverse():guards)}function bindGuard(guard,instance){if(instance)return function(){return guard.apply(instance,arguments)}}History.prototype.listen=function(cb){this.cb=cb},History.prototype.onReady=function(cb,errorCb){this.ready?cb():(this.readyCbs.push(cb),errorCb&&this.readyErrorCbs.push(errorCb))},History.prototype.onError=function(errorCb){this.errorCbs.push(errorCb)},History.prototype.transitionTo=function(location,onComplete,onAbort){var this$1=this,route=this.router.match(location,this.current);this.confirmTransition(route,function(){this$1.updateRoute(route),onComplete&&onComplete(route),this$1.ensureURL(),this$1.ready||(this$1.ready=!0,this$1.readyCbs.forEach(function(cb){cb(route)}))},function(err){onAbort&&onAbort(err),err&&!this$1.ready&&(this$1.ready=!0,this$1.readyErrorCbs.forEach(function(cb){cb(err)}))})},History.prototype.confirmTransition=function(route,onComplete,onAbort){var this$1=this,current=this.current,abort=function(err){isError(err)&&(this$1.errorCbs.length?this$1.errorCbs.forEach(function(cb){cb(err)}):(warn(!1,"uncaught error during route navigation:"),console.error(err))),onAbort&&onAbort(err)};if(isSameRoute(route,current)&&route.matched.length===current.matched.length)return this.ensureURL(),abort();var ref=function(current,next){var i,max=Math.max(current.length,next.length);for(i=0;i=0?href.slice(0,i):href)+"#"+path}function pushHash(path){supportsPushState?pushState(getUrl(path)):window.location.hash=path}function replaceHash(path){supportsPushState?replaceState(getUrl(path)):window.location.replace(getUrl(path))}var AbstractHistory=function(History$$1){function AbstractHistory(router,base){History$$1.call(this,router,base),this.stack=[],this.index=-1}return History$$1&&(AbstractHistory.__proto__=History$$1),AbstractHistory.prototype=Object.create(History$$1&&History$$1.prototype),AbstractHistory.prototype.constructor=AbstractHistory,AbstractHistory.prototype.push=function(location,onComplete,onAbort){var this$1=this;this.transitionTo(location,function(route){this$1.stack=this$1.stack.slice(0,this$1.index+1).concat(route),this$1.index++,onComplete&&onComplete(route)},onAbort)},AbstractHistory.prototype.replace=function(location,onComplete,onAbort){var this$1=this;this.transitionTo(location,function(route){this$1.stack=this$1.stack.slice(0,this$1.index).concat(route),onComplete&&onComplete(route)},onAbort)},AbstractHistory.prototype.go=function(n){var this$1=this,targetIndex=this.index+n;if(!(targetIndex<0||targetIndex>=this.stack.length)){var route=this.stack[targetIndex];this.confirmTransition(route,function(){this$1.index=targetIndex,this$1.updateRoute(route)})}},AbstractHistory.prototype.getCurrentLocation=function(){var current=this.stack[this.stack.length-1];return current?current.fullPath:"/"},AbstractHistory.prototype.ensureURL=function(){},AbstractHistory}(History),VueRouter=function(options){void 0===options&&(options={}),this.app=null,this.apps=[],this.options=options,this.beforeHooks=[],this.resolveHooks=[],this.afterHooks=[],this.matcher=createMatcher(options.routes||[],this);var mode=options.mode||"hash";switch(this.fallback="history"===mode&&!supportsPushState&&!1!==options.fallback,this.fallback&&(mode="hash"),inBrowser||(mode="abstract"),this.mode=mode,mode){case"history":this.history=new HTML5History(this,options.base);break;case"hash":this.history=new HashHistory(this,options.base,this.fallback);break;case"abstract":this.history=new AbstractHistory(this,options.base);break;default:assert(!1,"invalid mode: "+mode)}},prototypeAccessors={currentRoute:{configurable:!0}};function registerHook(list,fn){return list.push(fn),function(){var i=list.indexOf(fn);i>-1&&list.splice(i,1)}}return VueRouter.prototype.match=function(raw,current,redirectedFrom){return this.matcher.match(raw,current,redirectedFrom)},prototypeAccessors.currentRoute.get=function(){return this.history&&this.history.current},VueRouter.prototype.init=function(app){var this$1=this;if(assert(install.installed,"not installed. Make sure to call `Vue.use(VueRouter)` before creating root instance."),this.apps.push(app),!this.app){this.app=app;var history=this.history;if(history instanceof HTML5History)history.transitionTo(history.getCurrentLocation());else if(history instanceof HashHistory){var setupHashListener=function(){history.setupListeners()};history.transitionTo(history.getCurrentLocation(),setupHashListener,setupHashListener)}history.listen(function(route){this$1.apps.forEach(function(app){app._route=route})})}},VueRouter.prototype.beforeEach=function(fn){return registerHook(this.beforeHooks,fn)},VueRouter.prototype.beforeResolve=function(fn){return registerHook(this.resolveHooks,fn)},VueRouter.prototype.afterEach=function(fn){return registerHook(this.afterHooks,fn)},VueRouter.prototype.onReady=function(cb,errorCb){this.history.onReady(cb,errorCb)},VueRouter.prototype.onError=function(errorCb){this.history.onError(errorCb)},VueRouter.prototype.push=function(location,onComplete,onAbort){this.history.push(location,onComplete,onAbort)},VueRouter.prototype.replace=function(location,onComplete,onAbort){this.history.replace(location,onComplete,onAbort)},VueRouter.prototype.go=function(n){this.history.go(n)},VueRouter.prototype.back=function(){this.go(-1)},VueRouter.prototype.forward=function(){this.go(1)},VueRouter.prototype.getMatchedComponents=function(to){var route=to?to.matched?to:this.resolve(to).route:this.currentRoute;return route?[].concat.apply([],route.matched.map(function(m){return Object.keys(m.components).map(function(key){return m.components[key]})})):[]},VueRouter.prototype.resolve=function(to,current,append){var location=normalizeLocation(to,current||this.history.current,append,this),route=this.match(location,current),fullPath=route.redirectedFrom||route.fullPath;return{location:location,route:route,href:function(base,fullPath,mode){var path="hash"===mode?"#"+fullPath:fullPath;return base?cleanPath(base+"/"+path):path}(this.history.base,fullPath,this.mode),normalizedTo:location,resolved:route}},VueRouter.prototype.addRoutes=function(routes){this.matcher.addRoutes(routes),this.history.current!==START&&this.history.transitionTo(this.history.getCurrentLocation())},Object.defineProperties(VueRouter.prototype,prototypeAccessors),VueRouter.install=install,VueRouter.version="3.0.1",inBrowser&&window.Vue&&window.Vue.use(VueRouter),VueRouter});
\ No newline at end of file
diff --git a/dist/js/app.js b/dist/js/app.js
deleted file mode 100644
index f20a09d..0000000
--- a/dist/js/app.js
+++ /dev/null
@@ -1 +0,0 @@
-const carritoUsuario=[];window.addEventListener("hashchange",()=>{render(decodeURI(window.location.hash))});const render=e=>{switch(e){case"#registro":abrirRegistro();break;case"#iniciar-sesion":abrirInicioSesion();break;case"#usuarios/":abrirUsuarios();break;case"#usuarios/mi-cuenta":abrirMiCuenta();break;case"#usuarios/pagos":abrirCarrito();break;case"#staff/":abrirStaff();break;default:return void abrirPagPrin()}},sectionP=document.getElementById("sectionP"),contenedorInicioRegistro=document.getElementById("contenedorInicio-Registro"),formInicioRegistro=document.getElementById("inicio_registro"),sectionS=document.getElementById("sectionS"),sectionCarrito=document.getElementById("sectionCarrito"),manipularTopBar=e=>{switch(e){case 1:cambiarProgreso(25);break;case 2:cancelarTransicion(),cambiarProgreso(50);break;case 3:cancelarTransicion(),cambiarProgreso(75);break;default:cancelarTransicion(),reiniciarTopBar()}},abrirUsuarios=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(formInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{200===e.status&&4===e.readyState?(cambiarProgreso(100).then(ocultarTopBar),abrirElemF(sectionS,()=>{sectionS.innerHTML=e.responseText,(()=>new Promise((e,t)=>{const r=new XMLHttpRequest;r.onreadystatechange=(()=>{if(200===r.status&&4===r.readyState){const t=JSON.parse(r.responseText),n=document.getElementById("productos");let a=document.createElement("div");a.className="row";let i=0;for(const e in t)if(t.hasOwnProperty(e)){const r=t[e];++i>=4&&(n.appendChild(a),n.appendChild(document.createElement("br")),(a=document.createElement("div")).className="row",i=1);const o=document.createElement("div");o.className="col-4 caja plato";const s=document.createElement("img");s.className="image",s.src=r.imgUrl,o.appendChild(s);const c=document.createElement("div");c.className="plato--Titulo",c.innerText=r.nombre,o.appendChild(c),o.appendChild(document.createElement("br"));const d=document.createElement("div");d.className="plato--Descripcion",d.innerText=r.descripcion,o.appendChild(d),o.appendChild(document.createElement("br"));const l=document.createElement("div");l.className="plato--Precio",l.innerText=`${r.precio}`,o.appendChild(l);const p=document.createElement("div");p.className="plato--Cantidad",p.appendChild(document.createTextNode("Cantidad: "));const m=document.createElement("span"),u=document.createElement("i");u.className="material-icons plato--Cantidad--Icon",u.innerText="remove",u.addEventListener("click",()=>{const e=parseInt(m.innerText);m.innerText=e>1?e-1:"1"}),p.appendChild(u),m.innerText="1",p.appendChild(m);const h=document.createElement("i");h.className="material-icons plato--Cantidad--Icon",h.innerText="add",h.addEventListener("click",()=>{const e=parseInt(m.innerText);m.innerText=e>0?e+1:"1"}),p.appendChild(h),o.appendChild(p),o.appendChild(document.createElement("br"));const E=document.createElement("button");E.className="botonAddCart",E.addEventListener("click",()=>{const r=parseInt(m.innerText);if(r>0){const n=t[e];n.cantidad=r,carritoUsuario.push(n),console.log(`JSON del usuario|>\n${JSON.stringify(carritoUsuario)}`),window.location.replace("./#usuarios/pagos")}else alert("")}),E.innerHTML="add_shopping_cart Añadir al carrito",o.appendChild(E),a.appendChild(o)}n.appendChild(a),e()}}),r.open("POST","./usuarios/platos.json",!0),r.setRequestHeader("Content-type","application/x-www-form-urlencoded"),r.send()}))()})):manipularTopBar(e.readyState)}),e.open("POST","./usuarios/index.php",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirMiCuenta=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(formInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{200===e.status&&4===e.readyState?(cambiarProgreso(100).then(ocultarTopBar),abrirElemF(sectionS,()=>{sectionS.innerHTML=e.responseText})):manipularTopBar(e.readyState)}),e.open("POST","./usuarios/mi-cuenta.php",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirCarrito=()=>{reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(formInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionS),abrirElemF(sectionCarrito)},abrirStaff=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(formInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{200===e.status&&4===e.readyState?(cambiarProgreso(100).then(ocultarTopBar),abrirElemF(sectionS,()=>{sectionS.innerHTML=e.responseText})):manipularTopBar(e.readyState)}),e.open("POST","./staff/",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirInicioSesion=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{if(200===e.status&&4===e.readyState){cambiarProgreso(100).then(ocultarTopBar);const t=document.getElementById("inicio_registro");abrirElemF(t,()=>{t.innerHTML=e.responseText})}else manipularTopBar(e.readyState)}),e.open("POST","./iniciar-sesion.php",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirRegistro=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{if(200===e.status&&4===e.readyState){cambiarProgreso(100).then(ocultarTopBar);const t=document.getElementById("inicio_registro");abrirElemF(t,()=>{t.innerHTML=e.responseText})}else manipularTopBar(e.readyState)}),e.open("POST","./registro.php",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirPagPrin=()=>{const e=document.getElementById("inicio_registro");cerrarElemF(e,()=>e.innerHTML=""),cerrarElemF(sectionS,()=>sectionS.innerHTML=""),cerrarElemF(sectionCarrito),abrirElemF(contenedorInicioRegistro),abrirElemF(sectionP)},collapseSection=e=>new Promise((t,r)=>{let n=e.scrollHeight,a=e.style.transition;e.style.transition="",requestAnimationFrame(function(){e.style.height=n+"px",e.style.transition=a,requestAnimationFrame(function(){e.style.height="0px",setTimeout(()=>{t("Termine de ocultar we v':")},160)})}),e.setAttribute("data-collapsed","true")}),expandSection=e=>new Promise((t,r)=>{let n=e.scrollHeight;e.style.height=n+"px",e.addEventListener("transitionend",function(r){e.removeEventListener("transitionend",arguments.callee),e.style.height=null,setTimeout(()=>{t("Termine de ampliar we v':")},0)}),e.setAttribute("data-collapsed","false")}),abrirElemF=(e,t,r)=>{"true"===e.getAttribute("data-collapsed")?(void 0!==t&&t(),expandSection(e).then(()=>{void 0!==r&&r()})):collapseSection(e).then(()=>{void 0!==t&&t(),expandSection(e).then(()=>{void 0!==r&&r()})})},cerrarElemF=(e,t)=>{"false"===e.getAttribute("data-collapsed")&&collapseSection(e).then(()=>{void 0!==t&&t()})};render(decodeURI(window.location.hash));const carrito=new Vue({el:"#carrito",data:{item:carritoUsuario,descuento:0},computed:{cantidadItems:function(){let e=0;for(const t in this.item)e++;return e},subTotal:function(){let e=0;for(const t in this.item)if(this.item.hasOwnProperty(t)){const r=this.item[t];e+=r.precio*r.cantidad}return e},total:function(){return this.subTotal-this.descuento},noEstaVacio:function(){for(const e in this.item)return!0;return!1}},methods:{restarCantidad:function(e){const t=parseInt(e.cantidad);t>0&&(e.cantidad=t-1)},aumentarCantidad:function(e){const t=parseInt(e.cantidad);t>=0&&(e.cantidad=t+1)}}}),topBar=document.createElement("div");topBar.style.position="fixed",topBar.style.minHeight="3px",topBar.style.backgroundColor="red",topBar.style.zIndex="1";const transitionD=500;topBar.style.transition="min-width 500ms, opacity 250ms",topBar.style.minWidth="0";let promesaActual,widthDestino=0;document.body.appendChild(topBar);const cambiarProgreso=e=>(widthDestino=e,promesaActual=new Promise((t,r)=>{topBar.style.minWidth=`${e}%`,setTimeout(()=>t(),500)})),cancelarTransicion=()=>{const e=topBar.style.transition;topBar.style.transition="",topBar.style.minWidth=`${widthDestino}%`,topBar.style.transition=e},ocultarTopBar=()=>{topBar.style.opacity="0",setTimeout(()=>{topBar.style.minWidth="0%"},250)},reiniciarTopBar=()=>{const e=topBar.style.transition;topBar.style.transition="",topBar.style.minWidth="0",topBar.style.opacity="1",topBar.style.transition=e};
\ No newline at end of file
diff --git a/dist/js/base.min.js b/dist/js/base.min.js
deleted file mode 100644
index 53b62db..0000000
--- a/dist/js/base.min.js
+++ /dev/null
@@ -1 +0,0 @@
-carritoUsuario=[];window.addEventListener("hashchange",()=>{render(decodeURI(window.location.hash))});const render=e=>{switch(e){case"#registro":abrirRegistro();break;case"#iniciar-sesion":abrirInicioSesion();break;case"#usuarios/":abrirUsuarios();break;case"#usuarios/mi-cuenta":abrirMiCuenta();break;case"#usuarios/pagos":abrirCarrito();break;case"#staff/":abrirStaff();break;default:return void abrirPagPrin()}},sectionP=document.getElementById("sectionP"),contenedorInicioRegistro=document.getElementById("contenedorInicio-Registro"),formInicioRegistro=document.getElementById("inicio_registro"),sectionS=document.getElementById("sectionS"),sectionCarrito=document.getElementById("sectionCarrito"),manipularTopBar=e=>{switch(e){case 1:cambiarProgreso(25);break;case 2:cancelarTransicion(),cambiarProgreso(50);break;case 3:cancelarTransicion(),cambiarProgreso(75);break;default:cancelarTransicion(),reiniciarTopBar()}},abrirUsuarios=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(formInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{200===e.status&&4===e.readyState?(cambiarProgreso(100).then(ocultarTopBar),abrirElemF(sectionS,()=>{sectionS.innerHTML=e.responseText,(()=>new Promise((e,t)=>{const r=new XMLHttpRequest;r.onreadystatechange=(()=>{if(200===r.status&&4===r.readyState){const t=JSON.parse(r.responseText),n=document.getElementById("productos");let a=document.createElement("div");a.className="row";let i=0;for(const e in t)if(t.hasOwnProperty(e)){const r=t[e];++i>=4&&(n.appendChild(a),n.appendChild(document.createElement("br")),(a=document.createElement("div")).className="row",i=1);const o=document.createElement("div");o.className="col-4 caja plato";const c=document.createElement("img");c.className="image",c.src=r.imgUrl,o.appendChild(c);const s=document.createElement("div");s.className="plato--Titulo",s.innerText=r.nombre,o.appendChild(s),o.appendChild(document.createElement("br"));const d=document.createElement("div");d.className="plato--Descripcion",d.innerText=r.descripcion,o.appendChild(d),o.appendChild(document.createElement("br"));const l=document.createElement("div");l.className="plato--Precio",l.innerText=`${r.precio}`,o.appendChild(l);const m=document.createElement("div");m.className="plato--Cantidad",m.appendChild(document.createTextNode("Cantidad: "));const p=document.createElement("span"),u=document.createElement("i");u.className="material-icons plato--Cantidad--Icon",u.innerText="remove",u.addEventListener("click",()=>{const e=parseInt(p.innerText);p.innerText=e>1?e-1:"1"}),m.appendChild(u),p.innerText="1",m.appendChild(p);const h=document.createElement("i");h.className="material-icons plato--Cantidad--Icon",h.innerText="add",h.addEventListener("click",()=>{const e=parseInt(p.innerText);p.innerText=e>0?e+1:"1"}),m.appendChild(h),o.appendChild(m),o.appendChild(document.createElement("br"));const E=document.createElement("button");E.className="botonAddCart",E.addEventListener("click",()=>{const r=parseInt(p.innerText);if(r>0){const n=t[e];n.cantidad=r,carritoUsuario.push(n),console.log(`JSON del usuario|>\n${JSON.stringify(carritoUsuario)}`),window.location.replace("./#usuarios/pagos")}else alert("")}),E.innerHTML="add_shopping_cart Añadir al carrito",o.appendChild(E),a.appendChild(o)}n.appendChild(a),e()}}),r.open("POST","./usuarios/platos.json",!0),r.setRequestHeader("Content-type","application/x-www-form-urlencoded"),r.send()}))()})):manipularTopBar(e.readyState)}),e.open("POST","./usuarios/index.php",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirMiCuenta=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(formInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{200===e.status&&4===e.readyState?(cambiarProgreso(100).then(ocultarTopBar),abrirElemF(sectionS,()=>{sectionS.innerHTML=e.responseText})):manipularTopBar(e.readyState)}),e.open("POST","./usuarios/mi-cuenta.php",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirCarrito=()=>{reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(formInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionS),abrirElemF(sectionCarrito)},abrirStaff=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(formInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{200===e.status&&4===e.readyState?(cambiarProgreso(100).then(ocultarTopBar),abrirElemF(sectionS,()=>{sectionS.innerHTML=e.responseText})):manipularTopBar(e.readyState)}),e.open("POST","./staff/",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirInicioSesion=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{if(200===e.status&&4===e.readyState){cambiarProgreso(100).then(ocultarTopBar);const t=document.getElementById("inicio_registro");abrirElemF(t,()=>{t.innerHTML=e.responseText})}else manipularTopBar(e.readyState)}),e.open("POST","./iniciar-sesion.php",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirRegistro=()=>{const e=new XMLHttpRequest;reiniciarTopBar(),cerrarElemF(contenedorInicioRegistro),cerrarElemF(sectionP),cerrarElemF(sectionCarrito),e.onreadystatechange=(()=>{if(200===e.status&&4===e.readyState){cambiarProgreso(100).then(ocultarTopBar);const t=document.getElementById("inicio_registro");abrirElemF(t,()=>{t.innerHTML=e.responseText})}else manipularTopBar(e.readyState)}),e.open("POST","./registro.php",!0),e.setRequestHeader("Content-type","application/x-www-form-urlencoded"),e.send()},abrirPagPrin=()=>{const e=document.getElementById("inicio_registro");cerrarElemF(e,()=>e.innerHTML=""),cerrarElemF(sectionS,()=>sectionS.innerHTML=""),cerrarElemF(sectionCarrito),abrirElemF(contenedorInicioRegistro),abrirElemF(sectionP)},collapseSection=e=>new Promise((t,r)=>{let n=e.scrollHeight,a=e.style.transition;e.style.transition="",requestAnimationFrame(function(){e.style.height=n+"px",e.style.transition=a,requestAnimationFrame(function(){e.style.height="0px",setTimeout(()=>{t("Termine de ocultar we v':")},160)})}),e.setAttribute("data-collapsed","true")}),expandSection=e=>new Promise((t,r)=>{let n=e.scrollHeight;e.style.height=n+"px",e.addEventListener("transitionend",function(r){e.removeEventListener("transitionend",arguments.callee),e.style.height=null,setTimeout(()=>{t("Termine de ampliar we v':")},0)}),e.setAttribute("data-collapsed","false")}),abrirElemF=(e,t,r)=>{"true"===e.getAttribute("data-collapsed")?(void 0!==t&&t(),expandSection(e).then(()=>{void 0!==r&&r()})):collapseSection(e).then(()=>{void 0!==t&&t(),expandSection(e).then(()=>{void 0!==r&&r()})})},cerrarElemF=(e,t)=>{"false"===e.getAttribute("data-collapsed")&&collapseSection(e).then(()=>{void 0!==t&&t()})};render(decodeURI(window.location.hash));const carrito=new Vue({el:"#carrito",data:{item:carritoUsuario,descuento:0},computed:{cantidadItems:function(){let e=0;for(const t in this.item)e++;return e},subTotal:function(){let e=0;for(const t in this.item)if(this.item.hasOwnProperty(t)){const r=this.item[t];e+=r.precio*r.cantidad}return e},total:function(){return this.subTotal-this.descuento},noEstaVacio:function(){for(const e in this.item)return!0;return!1}},methods:{restarCantidad:function(e){const t=parseInt(e.cantidad);t>0&&(e.cantidad=t-1)},aumentarCantidad:function(e){const t=parseInt(e.cantidad);t>=0&&(e.cantidad=t+1)}}});
diff --git a/dist/js/topbar.min.js b/dist/js/topbar.min.js
deleted file mode 100644
index 7cd51b6..0000000
--- a/dist/js/topbar.min.js
+++ /dev/null
@@ -1 +0,0 @@
-const topBar=document.createElement("div");topBar.style.position="fixed",topBar.style.minHeight="3px",topBar.style.backgroundColor="red",topBar.style.zIndex="1";const transitionD=500;topBar.style.transition="min-width 500ms, opacity 250ms",topBar.style.minWidth="0";let promesaActual,widthDestino=0;document.body.appendChild(topBar);const cambiarProgreso=t=>(widthDestino=t,promesaActual=new Promise((o,i)=>{topBar.style.minWidth=`${t}%`,setTimeout(()=>o(),500)})),cancelarTransicion=()=>{const t=topBar.style.transition;topBar.style.transition="",topBar.style.minWidth=`${widthDestino}%`,topBar.style.transition=t},ocultarTopBar=()=>{topBar.style.opacity="0",setTimeout(()=>{topBar.style.minWidth="0%"},250)},reiniciarTopBar=()=>{const t=topBar.style.transition;topBar.style.transition="",topBar.style.minWidth="0",topBar.style.opacity="1",topBar.style.transition=t};
\ No newline at end of file
diff --git a/index.php b/index.php
deleted file mode 100644
index 9e80f46..0000000
--- a/index.php
+++ /dev/null
@@ -1,176 +0,0 @@
-
-
-
- Cocina Francesa
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/iniciar-sesion.php b/iniciar-sesion.php
deleted file mode 100644
index fddc1bc..0000000
--- a/iniciar-sesion.php
+++ /dev/null
@@ -1,67 +0,0 @@
-
-
- Inicia Sesión.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- O inicia sesión con tu correo:
-
-
-
-
-
- ¿No tienes una cuenta?
-
- Regístrate
-
-
-
-
-
-
\ No newline at end of file
diff --git a/package.json b/package.json
deleted file mode 100644
index ca9b089..0000000
--- a/package.json
+++ /dev/null
@@ -1,26 +0,0 @@
-{
- "name": "ihc",
- "version": "1.0.0",
- "description": "A simple meb application for a 'French Restaurant'",
- "main": "index.php",
- "scripts": {
- "uglify": "uglifyjs src/js/*.js -m -c -o dist/js/app.js",
- "sass": "sass -s compressed src/sass:dist/css",
- "compile": "npm run uglify && npm run sass"
- },
- "repository": {
- "type": "git",
- "url": "git+https://gitlab.com/Araozu/ihc-proyect.git"
- },
- "keywords": [
- "ihc",
- "unsa",
- "2018"
- ],
- "author": "Fernando Araoz Morales",
- "license": "MIT",
- "bugs": {
- "url": "https://gitlab.com/Araozu/ihc-proyect/issues"
- },
- "homepage": "https://gitlab.com/Araozu/ihc-proyect#readme"
-}
diff --git a/registro.php b/registro.php
deleted file mode 100644
index e7b88f8..0000000
--- a/registro.php
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
- Registrate para tener lo mejor de la cocina francesa en la comodida de tu casa.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- O crea tu cuenta con tu correo electrónico:
-
-
-
-
-
-
- ¿Ya tienes una cuenta?
-
- Inicia Sesion
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/componentes/carrito.vue b/src/componentes/carrito.vue
deleted file mode 100644
index f86d461..0000000
--- a/src/componentes/carrito.vue
+++ /dev/null
@@ -1,94 +0,0 @@
-
-
-
-
-
-
-
-
-
-
- Carrito de compras
-
-
-
Seguir comprando
-
-
-
-
-
-
-
-
-
-
-
{{ producto.nombre }}
-
-
{{ producto.precio }}
-
Cantidad:
- remove
- {{ producto.cantidad }}
- add
-
-
-
{{ producto.precio * producto.cantidad }}
-
-
-
-
-
- No hay nada en tu carrito de compras :c
-
-
-
-
-
-
-
-
-
-
- {{ cantidadItems }} Producto{{ (cantidadItems>1 || cantidadItems === 0) ? 's': '' }}
-
-
- {{ subTotal }} S/.
-
-
-
-
- Descuentos:
-
-
- {{ descuento }} S/.
-
-
-
-
-
-
- Total:
-
-
- {{ total }} S/.
-
-
-
-
-
- Completar Transaccion
-
-
-
- No hay nada en tu carrito de compras :c
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/componentes/header-mini.vue b/src/componentes/header-mini.vue
deleted file mode 100644
index 5335abf..0000000
--- a/src/componentes/header-mini.vue
+++ /dev/null
@@ -1,7 +0,0 @@
-
diff --git a/src/componentes/headerMin.vue b/src/componentes/headerMin.vue
deleted file mode 100644
index 6b6760f..0000000
--- a/src/componentes/headerMin.vue
+++ /dev/null
@@ -1,23 +0,0 @@
-
diff --git a/src/componentes/inicio.vue b/src/componentes/inicio.vue
deleted file mode 100644
index a21226c..0000000
--- a/src/componentes/inicio.vue
+++ /dev/null
@@ -1,44 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et
- dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip
- ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu
- fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia
- deserunt mollit anim id est laborum.
-
-
-
-
-
-
-
- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et
- dolore magna aliqua. Congue quisque egestas diam in arcu cursus euismod quis. Mi tempus imperdiet nulla
- malesuada pellentesque elit eget gravida. Tempus imperdiet nulla malesuada pellentesque elit eget
- gravida
- cum. Commodo elit at imperdiet dui accumsan sit amet. In nulla posuere sollicitudin aliquam ultrices
- sagittis.
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/componentes/mi-footer.vue b/src/componentes/mi-footer.vue
deleted file mode 100644
index e6dc3fa..0000000
--- a/src/componentes/mi-footer.vue
+++ /dev/null
@@ -1,11 +0,0 @@
-
-
-
diff --git a/src/componentes/navBar.vue b/src/componentes/navBar.vue
deleted file mode 100644
index 186098d..0000000
--- a/src/componentes/navBar.vue
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
-
diff --git a/src/componentes/tienda.vue b/src/componentes/tienda.vue
deleted file mode 100644
index e401b75..0000000
--- a/src/componentes/tienda.vue
+++ /dev/null
@@ -1,48 +0,0 @@
-
-
-
-
-
-
-
-
- Tienda
-
- Ver mi cuenta | Ver mi carrito
-
-
-
-
-
-
-
-
-
- {{ item.nombre }}
-
-
-
- {{ item.descripcion }}
-
-
-
- {{ item.precio }}
-
-
-
- 1
- add
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/data/platos.json b/src/data/platos.json
deleted file mode 100644
index 3385cb9..0000000
--- a/src/data/platos.json
+++ /dev/null
@@ -1,50 +0,0 @@
-[
- {
- "nombre": "Soupe à l'oignon",
- "descripcion": "Sopa tradicional hecha con cebolla y carne.",
- "imgUrl": "https://www.expatica.com/media/upload/714571.jpg",
- "precio": 20
- },
- {
- "nombre": "Coq au vin",
- "descripcion": "Pollo cocinado con vino, hongos, carne de cerdo y ajo",
- "imgUrl": "https://www.expatica.com/media/upload/714572.jpg",
- "precio": 50
- },
- {
- "nombre": "Beef bourguignon",
- "descripcion": "Filete cocinado en vino, sasonado con especias",
- "imgUrl": "https://www.expatica.com/media/upload/714573.jpg",
- "precio": 30
- },
- {
- "nombre": "Cassoulet",
- "descripcion": "Guiso parecido a las habichuelas típicas españolas que se hace con alubias blancas o frijoles acompañadas de carne de diferentes animales",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Cassoulet-570x320.jpg",
- "precio": 22
- },
- {
- "nombre": "Fondue de queso",
- "descripcion": "Crema que se puede tomar bien como acompañante de otros ingredientes o bien mojando trozos de pan en él.",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Fondue-570x321.jpg",
- "precio": 5
- },
- {
- "nombre": "Ratatouille",
- "descripcion": "Elaborado con diversas hortalizas, es un plato natural de Niza y la región de Provenza, al sureste de Francia.",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Ratatouille-570x320.jpg",
- "precio": 35
- },
- {
- "nombre": "Magret de canard",
- "descripcion": "Un filete de carne magra, que suele provenir de un ganso o pato cebado",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Magret-de-Canard-570x320.jpg",
- "precio": 17
- },
- {
- "nombre": "Merluza al beurre blanc",
- "descripcion": "Este plato consiste en troncos o lomos de merluza que se sirven en salsa beurre blanc.",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Merluza-a-la-beurre-blanc-570x320.jpg",
- "precio": 22
- }
-]
\ No newline at end of file
diff --git a/src/js/base.js b/src/js/base.js
deleted file mode 100644
index 2b5f2de..0000000
--- a/src/js/base.js
+++ /dev/null
@@ -1,137 +0,0 @@
-const carritoUsuario = [];
-
-/* Height Transition by CSS Tricks. Returns a Promise */
-const collapseSection = element => {
- return new Promise((resolve, reject) => {
-
- // get the height of the element's inner content, regardless of its actual size
- let sectionHeight = element.scrollHeight;
-
- // temporarily disable all css transitions
- let elementTransition = element.style.transition;
- element.style.transition = '';
-
- // on the next frame (as soon as the previous style change has taken effect),
- // explicitly set the element's height to its current pixel height, so we
- // aren't transitioning out of 'auto'
-
-
- requestAnimationFrame(function () {
- element.style.height = sectionHeight + 'px';
- element.style.transition = elementTransition;
-
- // on the next frame (as soon as the previous style change has taken effect),
- // have the element transition to height: 0
- requestAnimationFrame(function () {
- element.style.height = 0 + 'px';
- setTimeout(() => {
- resolve("Termine de ocultar we v':");
- }, 160);
- });
- });
-
- // mark the section as "currently collapsed"
- element.setAttribute('data-collapsed', 'true');
- });
-};
-
-const expandSection = element => {
- return new Promise((resolve, reject) => {
- // get the height of the element's inner content, regardless of its actual size
- let sectionHeight = element.scrollHeight;
-
- // have the element transition to the height of its inner content
- element.style.height = sectionHeight + 'px';
-
- // when the next css transition finishes (which should be the one we just triggered)
- element.addEventListener('transitionend', function (e) {
- // remove this event listener so it only gets triggered once
- element.removeEventListener('transitionend', arguments.callee);
-
- // remove "height" from the element's inline styles, so it can return to its initial value
- element.style.height = null;
- setTimeout(() => {
- resolve("Termine de ampliar we v':");
- }, 0);
- });
-
- // mark the section as "currently not collapsed"
- element.setAttribute('data-collapsed', 'false');
- });
-};
-
-const abrirElemF = (element, midF, postF) => {
- if (element.getAttribute("data-collapsed") === "true") {
- if (midF !== undefined)
- midF();
- expandSection(element).then(() => {
- if (postF !== undefined)
- postF();
- });
- } else {
- collapseSection(element).then(() => {
- if (midF !== undefined)
- midF();
- expandSection(element).then(() => {
- if (postF !== undefined)
- postF();
- });
- });
- }
-};
-
-const cerrarElemF = (element, postF) => {
- if (element.getAttribute("data-collapsed") === "false") {
- collapseSection(element).then(() => {
- if (postF !== undefined)
- postF();
- });
- }
-};
-
-const carrito = new Vue({
- el: "#carrito",
- data: {
- item: carritoUsuario,
- descuento: 0
- },
- computed: {
- cantidadItems: function () {
- let items = 0;
- for (const i in this.item)
- items++;
- return items;
- },
- subTotal: function () {
- let subT = 0;
- for (const itemI in this.item ) {
- if (this.item.hasOwnProperty(itemI)){
- const item = this.item[itemI];
- subT += (item["precio"] * item["cantidad"]);
- }
- }
- return subT;
- },
- total: function () {
- return this.subTotal - this.descuento;
- },
- noEstaVacio: function () {
- for (const i in this.item) {
- return true;
- }
- return false;
- },
- },
- methods: {
- restarCantidad: function (elem) {
- const cantidad = parseInt(elem.cantidad);
- if (cantidad > 0)
- elem.cantidad = cantidad -1;
- },
- aumentarCantidad: function (elem) {
- const cantidad = parseInt(elem.cantidad);
- if (cantidad >= 0)
- elem.cantidad = cantidad+1;
- }
- }
-});
diff --git a/src/js/topbar.js b/src/js/topbar.js
deleted file mode 100644
index a6b170b..0000000
--- a/src/js/topbar.js
+++ /dev/null
@@ -1,46 +0,0 @@
-const topBar = document.createElement("div");
-topBar.style.position = "fixed";
-topBar.style.minHeight = "3px";
-topBar.style.backgroundColor = "red";
-topBar.style.zIndex = "1";
-
-const transitionD = 500;
-topBar.style.transition = `min-width ${transitionD}ms, opacity 250ms`;
-topBar.style.minWidth = "0";
-
-let widthDestino = 0;
-
-document.body.appendChild(topBar);
-
-let promesaActual;
-
-const cambiarProgreso = progreso => {
- widthDestino = progreso;
- promesaActual = new Promise((resolve, reject) => {
- topBar.style.minWidth = `${progreso}%`;
- setTimeout(() => resolve(),transitionD);
- });
- return promesaActual;
-};
-
-const cancelarTransicion = () => {
- const transiciones = topBar.style.transition;
- topBar.style.transition = "";
- topBar.style.minWidth = `${widthDestino}%`;
- topBar.style.transition = transiciones;
-};
-
-const ocultarTopBar = () => {
- topBar.style.opacity = "0";
- setTimeout(() => {
- topBar.style.minWidth = "0%";
- },250);
-};
-
-const reiniciarTopBar = () => {
- const transiciones = topBar.style.transition;
- topBar.style.transition = "";
- topBar.style.minWidth = `0`;
- topBar.style.opacity = "1";
- topBar.style.transition = transiciones;
-};
diff --git a/src/sass/base.sass b/src/sass/base.sass
deleted file mode 100644
index cdd3a0e..0000000
--- a/src/sass/base.sass
+++ /dev/null
@@ -1,429 +0,0 @@
-@import url('https://fonts.googleapis.com/css?family=Muli|Open+Sans')
-
-$fuenteTitulos: 'Muli'
-$fuentePrincipal: 'Open Sans'
-
-$colorPrincipalOscuro: #3d3d7c
-
-*
- box-sizing: border-box
-
-html, body
- margin: 0
- padding: 0
- font-family: $fuentePrincipal, sans-serif
-
-header
- background-color: #44A
- box-shadow: 0 5px 5px #999999
-
-nav
- background-color: #3d3d7c
- color: white
-
-section
- overflow: hidden
- transition: height 150ms ease-out
- height: auto
-
-footer
- background-color: #333
- color: #EEE
- box-shadow: inset 0 5px 5px #999999
- padding: 40px
-
-.contenedor
- max-width: 1200px
- width: 80%
- margin: auto
-
-.col-1
- width: 8.33%
-
-.col-2
- width: 16.66%
-
-.col-3
- width: 25%
-
-.col-4
- width: 33.33%
-
-.col-5
- width: 41.66%
-
-.col-6
- width: 50%
-
-.col-7
- width: 58.33%
-
-.col-8
- width: 66.66%
-
-.col-9
- width: 75%
-
-.col-10
- width: 83.33%
-
-.col-11
- width: 91.66%
-
-.col-12
- width: 100%
-
-[class*="col-"]
- float: left
-
-.row::after
- content: ""
- clear: both
- display: table
-
-.center
- text-align: center
-
-#tituloP
- padding: 30px
- color: white
- font:
- size: 50px
- family: $fuenteTitulos
-
-#tituloP--descripcion
- padding: 10px
- font:
- size: large
- family: $fuentePrincipal
-
-.tituloP--mini
- padding: 10px !important
- font:
- size: 40px !important
-
-.titulo--link
- color: white
- text-decoration: none
-
-.center
- text-align: center
-
-.boton
- display: inline-block
- margin: 20px
- border-radius: 3px
- box-shadow: 1px 1px 3px #090909
- padding: 10px 30px
- cursor: pointer
- text-decoration: none
-
-.mySeccion
- overflow: hidden
- transition: height 150ms ease-out
- height: auto
-
-#botonRegistro
- background-color: green
- color: white
- font-size: large
- transition: transform 200ms, box-shadow 200ms
-
-#botonRegistro:hover
- transform: translate(-1px, -1px)
- box-shadow: 2px 2px 7px #050505
-
-#botonInicioSesion
- background-color: white
- transition: transform 200ms, box-shadow 200ms
-
-#botonInicioSesion:hover
- transform: translate(-1px, -1px)
- box-shadow: 2px 2px 7px #050505
-
-#botonInicioSesion:visited
- color: black
-
-.contenido
- margin: 40px 0
-
-.image
- padding: 0 20px
- width: 100%
- height: auto
-
-.descripcionComida
- padding: 0 30px
- text-align: center
- font-size: large
-
-.inicio_registro
- color: white
-
-input
- min-width: 80%
- min-height: 40px
- padding: 10px
- color: #44A
- font-size: large
-
-.botonEnviarForm
- background-color: white
- box-shadow: 1px 1px 2px gray
- cursor: pointer
- border: none
- transition: background-color 250ms, color 250ms, transform 250ms, box-shadow 250ms
-
-.botonEnviarForm:hover
- background-color: #4949e2
- color: white
- transform: translate(-1px, -1px)
- box-shadow: 2px 2px 2px gray
-
-.google-button
- height: 40px
- border-width: 0
- background: white
- color: #737373
- border-radius: 5px
- white-space: nowrap
- box-shadow: 1px 1px 0 1px rgba(0, 0, 0, 0.05)
- transition-property: background-color, box-shadow
- transition-duration: 150ms
- transition-timing-function: ease-in-out
- padding: 0
- cursor: pointer
-
-.google-button:focus, .google-button:hover
- box-shadow: 1px 4px 5px 1px rgba(0, 0, 0, 0.1)
-
-.google-button:active
- background-color: #e5e5e5
- box-shadow: none
- transition-duration: 10ms
-
-.google-button__icon
- display: inline-block
- vertical-align: middle
- margin: 8px 0 8px 8px
- width: 18px
- height: 18px
- box-sizing: border-box
-
-.google-button__text
- display: inline-block
- vertical-align: middle
- padding: 0 24px
- font-size: 14px
- font-weight: bold
- font-family: 'Roboto', arial, sans-serif
-
-.unseen
- visibility: hidden
-
-.botonAddCart
- background-color: white
- padding: 5px
- color: #4444aa
- box-shadow: 0.1px 0.1px grey
- border-radius: 2px
- cursor: pointer
- font-size: large
- transition: background-color 250ms, color 250ms
- user-select: none
-
-.botonAddCart:hover
- background-color: #4444AA
- color: white
-
-.caja
- border-radius: 4px
- box-shadow: 1px 1px 2px gray
- padding: 15px
-
-.botonPayPal
- background-color: #0070ba
- color: white
- font-size: large
- padding: 10px
- border: none
- border-radius: 5px
- cursor: pointer
- margin: 0 5px
-
-.botonVisa
- @extend .botonPayPal
- background-color: #1a1f5e
-
-.linksNavBar
- margin: 0
- li
- list-style: none
- float: left
- transition: background-color 250ms
- a
- cursor: pointer
- display: inline-block
- padding: 15px
- color: white
- text-decoration: none
- &:after
- clear: both
- &:hover
- background-color: #35356a
-
-.plato--Titulo
- font:
- size: x-large
- weight: bold
- family: $fuenteTitulos
- color: #3d3d7c
-
-.plato--Descripcion
- font:
- size: large
- color: #333333
-
-.plato--Precio
- font-size: large
- &:before
- color: green
- content: "Precio unitario: "
- &:after
- content: " S/."
-
-.plato--Cantidad
- font:
- size: large
- weight: bold
- display: inline-table
- padding: 15px
-
-.plato--Cantidad--Icon
- display: table-cell
- vertical-align: top
- cursor: pointer
- transition: color 250ms
- -webkit-user-select: none
- -moz-user-select: none
- -ms-user-select: none
- user-select: none
- &:hover
- color: #4444aa
-
-.carrito
- text-align: left
-
-#carrito--elementos, #carrito--precio
- padding: 0 10px
-
-.carritoElem
- &:after
- clear: both
-
-.carritoElem--img
- float: left
- margin: 10px 20px
- width: 200px
-
-.carrito--subTotal
- text-align: right
- font:
- weight: bold
- family: $fuenteTitulos, sans-serif
- size: x-large
- &:before
- content: "Subtotal: "
- &:after
- content: " S/."
-
-.carrito--precio--contenido--titulo
- text-align: center
- font:
- family: $fuenteTitulos, sans-serif
- size: x-large
- weight: 900
-
-.carrito--precio--contenido--botonPagar
- display: inline-block
- width: 100%
- text-align: center
- padding: 10px
- background-color: #4444aa
- color: white
- border-radius: 3px
- cursor: pointer
- &:hover
- background-color: #3d3d7c
-
-#carrito--boton--seguircomprando
- margin: 10px 0
- padding: 10px 20px
- background-color: green
- color: white
- text-decoration: none
- border-radius: 4px
- &:visited
- color: white
-
-#carrito--tituloprincipal
- text-align: center
- font:
- size: xx-large
- family: $fuenteTitulos, sans-serif
- weight: 900
- margin: 10px 0
-
-.responsive-image
- padding: 0 20px
- width: 100%
- height: auto
-
-
-.tienda--titulo
- text-align: center
- font:
- family: $fuenteTitulos, sans-serif
- size: xx-large
- weight: 900
- margin: 10px 0
-
-.tienda--tarjeta
- padding: 10px
- margin: 10px 5px
- border-radius: 3px
- box-shadow: 2px 2px 5px gray
-
-.tienda--tarjeta--titulo
- font:
- size: x-large
- family: $fuenteTitulos, sans-serif
- color: $colorPrincipalOscuro
-
-.tienda--tarjeta--descripcion
-
-.tienda--tarjeta--precio
- &:before
- content: "Precio unitario: "
- color: green
- &:after
- content: " S/."
-
-.tienda--tarjeta--cantidad
- &:before
- content: "Cantidad remove "
-
-.tienda--tarjeta--botonComprar
- background-color: white
- color: $colorPrincipalOscuro
- padding: 10px
- cursor: pointer
- border-radius: 3px
- transition: color 100ms, background-color 100ms
- font:
- size: large
- weight: bold
- family: $fuenteTitulos
- &:hover
- background-color: $colorPrincipalOscuro
- color: white
\ No newline at end of file
diff --git a/usuarios/index.php b/usuarios/index.php
deleted file mode 100644
index f24a739..0000000
--- a/usuarios/index.php
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-
-
-
\ No newline at end of file
diff --git a/usuarios/mi-cuenta.php b/usuarios/mi-cuenta.php
deleted file mode 100644
index 3e99a1e..0000000
--- a/usuarios/mi-cuenta.php
+++ /dev/null
@@ -1,53 +0,0 @@
-
-
-
- Mi cuenta
-
-
Seguir comprando
-
-
-
-
- Mis datos:
-
-
- Nombre: {{ userName }}
- Correo electrónico: {{ userEmail }}
- Métodos de pago: {{ userPaymentMethods }}
-
-
-
- Historial de compras:
-
-
-
.
-
-
-
Soupe à l'oignon
-
-
Sopa tradicional hecha con cebolla y carne.
-
20 S/.
-
Fecha de compra: 17/09/18
-
-
-
.
-
-
-
-
.
-
-
-
Cassoulet
-
-
Plato de habas con carne y especies.
-
5 S/.
-
Fecha de compra: 15/09/18
-
-
-
.
-
-
-
-
-
-
\ No newline at end of file
diff --git a/usuarios/pagos.php b/usuarios/pagos.php
deleted file mode 100644
index bae17bd..0000000
--- a/usuarios/pagos.php
+++ /dev/null
@@ -1,84 +0,0 @@
-
-
-
-
- Carrito de compras
-
-
-
Seguir comprando
-
-
-
-
-
-
-
-
-
-
-
{{ producto.nombre }}
-
-
{{ producto.precio }}
-
Cantidad:
- remove
- {{ producto.cantidad }}
- add
-
-
-
{{ producto.precio * producto.cantidad }}
-
-
-
-
-
- No hay nada en tu carrito de compras :c
-
-
-
-
-
-
-
-
-
-
- {{ cantidadItems }} Producto{{ (cantidadItems>1 || cantidadItems === 0) ? 's': '' }}
-
-
- {{ subTotal }} S/.
-
-
-
-
- Descuentos:
-
-
- {{ descuento }} S/.
-
-
-
-
-
-
- Total:
-
-
- {{ total }} S/.
-
-
-
-
-
- Completar Transaccion
-
-
-
- No hay nada en tu carrito de compras :c
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/usuarios/platos.json b/usuarios/platos.json
deleted file mode 100644
index 3385cb9..0000000
--- a/usuarios/platos.json
+++ /dev/null
@@ -1,50 +0,0 @@
-[
- {
- "nombre": "Soupe à l'oignon",
- "descripcion": "Sopa tradicional hecha con cebolla y carne.",
- "imgUrl": "https://www.expatica.com/media/upload/714571.jpg",
- "precio": 20
- },
- {
- "nombre": "Coq au vin",
- "descripcion": "Pollo cocinado con vino, hongos, carne de cerdo y ajo",
- "imgUrl": "https://www.expatica.com/media/upload/714572.jpg",
- "precio": 50
- },
- {
- "nombre": "Beef bourguignon",
- "descripcion": "Filete cocinado en vino, sasonado con especias",
- "imgUrl": "https://www.expatica.com/media/upload/714573.jpg",
- "precio": 30
- },
- {
- "nombre": "Cassoulet",
- "descripcion": "Guiso parecido a las habichuelas típicas españolas que se hace con alubias blancas o frijoles acompañadas de carne de diferentes animales",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Cassoulet-570x320.jpg",
- "precio": 22
- },
- {
- "nombre": "Fondue de queso",
- "descripcion": "Crema que se puede tomar bien como acompañante de otros ingredientes o bien mojando trozos de pan en él.",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Fondue-570x321.jpg",
- "precio": 5
- },
- {
- "nombre": "Ratatouille",
- "descripcion": "Elaborado con diversas hortalizas, es un plato natural de Niza y la región de Provenza, al sureste de Francia.",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Ratatouille-570x320.jpg",
- "precio": 35
- },
- {
- "nombre": "Magret de canard",
- "descripcion": "Un filete de carne magra, que suele provenir de un ganso o pato cebado",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Magret-de-Canard-570x320.jpg",
- "precio": 17
- },
- {
- "nombre": "Merluza al beurre blanc",
- "descripcion": "Este plato consiste en troncos o lomos de merluza que se sirven en salsa beurre blanc.",
- "imgUrl": "https://www.viajejet.com/wp-content/viajes/Merluza-a-la-beurre-blanc-570x320.jpg",
- "precio": 22
- }
-]
\ No newline at end of file