diff --git a/web/forms/ecomerce/basket/ui.xml b/web/forms/ecomerce/basket/ui.xml
index df7a9b9e..6389b2f1 100755
--- a/web/forms/ecomerce/basket/ui.xml
+++ b/web/forms/ecomerce/basket/ui.xml
@@ -2,28 +2,32 @@
ShoppingBasket
-
-
-
-
-
-
- Catalog
-
-
-
- Checkout
-
+
+
+
+
diff --git a/web/forms/ecomerce/catalog/catalog.js b/web/forms/ecomerce/catalog/catalog.js
index 95fddb94..6528432d 100755
--- a/web/forms/ecomerce/catalog/catalog.js
+++ b/web/forms/ecomerce/catalog/catalog.js
@@ -2,6 +2,8 @@
Vn.Catalog = new Class
({
Extends: Vn.Module
+
+ ,_menuShown: false
,open: function ()
{
@@ -22,12 +24,7 @@ Vn.Catalog = new Class
this.conn.execQuery (query, this.onBasketForGuest.bind (this));
}
}
-
- ,deactivate: function ()
- {
- this.gui.$('top-bar').style.backgroundColor = '';
- }
-
+
,onBasketForGuest: function ()
{
this.onBasketCheck (true);
@@ -40,11 +37,20 @@ Vn.Catalog = new Class
this.basketChecked = true;
this.open ();
+
+ document.body.appendChild (this.$('right-panel'));
this.popup = new Htk.Popup ();
this.popup.setChildNode (this.$('lots-popup'));
}
+ ,deactivate: function ()
+ {
+ this.parent ();
+ this.gui.$('top-bar').style.backgroundColor = '';
+ Vn.Node.remove (this.$('right-panel'));
+ }
+
,typeRenderer: function (builder, form)
{
var link = builder.$('link');
@@ -67,7 +73,7 @@ Vn.Catalog = new Class
,onTypeChange: function ()
{
- if (Vn.isMobile () && this.$('type').value)
+ if (this._menuShown && this.$('type').value)
this.hideMenu ();
var realms = this.$('realms-model');
@@ -88,13 +94,7 @@ Vn.Catalog = new Class
}
this.gui.$('top-bar').style.backgroundColor = color;
-/*
- var tr = this.$('items-grid').getNode ()
- .getElementsByTagName ('thead')[0]
- .getElementsByTagName ('tr')[0];
- //.querySelector ('thead tr');
- tr.style.backgroundColor = color;
-*/ }
+ }
,refreshTitle: function (title)
{
@@ -138,24 +138,28 @@ Vn.Catalog = new Class
batch.changed ();
}
- ,onMenuClick: function (event)
+ ,onRightPanelClick: function (event)
{
event.stopPropagation ();
}
,onShowMenuClick: function (event)
{
+ this._menuShown = true;
event.stopPropagation ();
this.gui.showBackground ();
- this.$('menu').style.display = 'block';
+ Vn.Node.addClass (this.$('right-panel'), 'show');
this.hideMenuCallback = this.hideMenu.bind (this);
document.addEventListener ('click', this.hideMenuCallback);
}
,hideMenu: function ()
{
+ if (!this._menuShown)
+ return;
+
this.gui.hideBackground ();
- this.$('menu').style.display = 'none';
+ Vn.Node.removeClass (this.$('right-panel'), 'show');
document.removeEventListener ('click', this.hideMenuCallback);
this.hideMenuCallback = null;
}
@@ -212,7 +216,7 @@ Vn.Catalog = new Class
,onGridAddItemClick: function (button, form)
{
- this.showAmountPopup (button, form.row);
+ this.showAmountPopup (button.getNode (), form.row);
}
,onAddItemClick: function (column, value, row, button)
diff --git a/web/forms/ecomerce/catalog/style.css b/web/forms/ecomerce/catalog/style.css
index 623fe3e5..f896ec78 100755
--- a/web/forms/ecomerce/catalog/style.css
+++ b/web/forms/ecomerce/catalog/style.css
@@ -32,32 +32,29 @@
max-width: 50em;
min-width: 25em;
}
-
.catalog .footer-message
{
padding-bottom: 1em;
text-align: center;
}
+.htk-toast
+{
+ margin-left: -11em;
+}
/* Topbar */
-.catalog .action-bar
+.action-bar > div > .search
{
- max-width: 15em;
-}
-.search
-{
- float: left;
- display: block;
+ margin-top: .8em;
background-color: white;
- height: 2.2em;
- padding: 0;
+ height: 2.3em;
}
.search > input
{
margin: 0;
border: none;
- width: 10em;
+ width: 8em;
box-shadow: none;
}
.search > input:focus
@@ -66,18 +63,18 @@
}
.search > img
{
- margin: 0.4em;
- margin-top: 0;
+ margin: 0;
+ margin-left: .4em;
vertical-align: middle;
}
/* Menu */
-.catalog div.menu
+.right-panel
{
position: absolute;
z-index: 20;
- top: 0;
+ top: 3.9em;
bottom: 0;
right: 0;
width: 17em;
@@ -129,7 +126,7 @@ button.basket:hover
.types-box
{
position: absolute;
- top: 14.6em;
+ top: 11.5em;
bottom: 0;
right: 0;
left: 0;
@@ -268,18 +265,18 @@ td.third-category
right: .5em;
}
+/* Transitions */
+
+.right-panel
+{
+ transition: right .3s;
+}
+
/* Mobile */
.catalog-actions button.menu
{
- float: left;
display: none;
- border: none;
- background-color: transparent;
- box-shadow: none;
- padding: 0.3em;
- padding-left: 0;
- margin-left: 0;
}
.catalog-actions button.menu > img
{
@@ -292,9 +289,14 @@ td.third-category
{
display: block;
}
- .catalog div.menu
+ .right-panel
{
- display: none;
+ top: 0;
+ right: -17em;
+ }
+ .right-panel.show
+ {
+ right: 0;
}
.catalog div.center
{
diff --git a/web/forms/ecomerce/catalog/ui.xml b/web/forms/ecomerce/catalog/ui.xml
index aff6192a..457b9977 100755
--- a/web/forms/ecomerce/catalog/ui.xml
+++ b/web/forms/ecomerce/catalog/ui.xml
@@ -62,11 +62,21 @@
Catalog
-
+
+
+
@@ -103,11 +113,17 @@
IndicativePhotos
--->
+-->