﻿TESCO.sites.Configuration.merge({
    "application" : {
        "domain" : {
            "zone" : ".com"
        }
    },
    "carousel" : {
		"step": 3,
		"paginationEnabled" : true
	},
	"collapse" : {
		"interval" : 10,
		"blender": {
			"expand" : TESCO.UI.effects.blender.sinusoidal,
			"collapse" : TESCO.UI.effects.blender.exponential
		},
	    "steps": 20
	},
    "colour": {
	    "blender": TESCO.UI.effects.blender.linear,
	    "interval": 50,
	    "steps": 10,
	    "highlight": [255, 255, 128],
	    "warn": TESCO.UI.effects.Colour.palette.red,
	    "confirm": [192, 255, 167]
    },
	"tooltips" : {
		"showDelay"	: 400,
		"offset" : 4,
		"duration" : 5000
	},
	"infoContainer" : {
		"top" : 0,
		"right" : 15,
		"left" : 15,
		"bottom" : 20
	},
	"flyout" : {
		"transient" : {
		    "hover" : {
		        "sensitivity" : 7,
                "interval" : 100
		    }
		}
	},
    "entities" : {
		"product": {
			"updateWait": 1000  // basket update buffer timeout
		}
	}
});

new TESCO.UI.Window.Relationship("help", "menubar=yes,width=720,height=600,toolbar=no,scrollbars=yes,status=no,resizable=yes,location=yes,titlebar=yes");
new TESCO.UI.Window.Relationship("external", "menubar=yes,toolbar=yes,scrollbars=yes,status=yes,resizable=yes,location=yes,titlebar=yes");

//TESCO.$("sites.UI.Flyout").Factory = (function() {

//    var _constructor = function() {
//        var _flyoutCollection = TESCO.system.DOM.node.getElementsByClassName(document.getElementById("mainContent"), 'productMidi');
//        var _productID;

//        for (var i = 0, L = _flyoutCollection.length; i < L; i++) {
//            _productID = _flyoutCollection[i].firstChild.id;
//            _productID = _productID.substr(2);
//            _productID = _productID.substr(0, _productID.length - 7);
//            TESCO.UI.Flyout.cache.setItem("carouselProduct" + _productID, _flyoutCollection[i]);
//        }
//        new TESCO.UI.Flyout.Modal(document.getElementById("mainContent"), TESCO.UI.Flyout.position.x.left, "infoProductContainerMini");

//        return this;
//    }
//    return _constructor;
//})();