Skip to content

Commit

Permalink
version 3.5.6
Browse files Browse the repository at this point in the history
  • Loading branch information
dgofman committed Jun 16, 2017
1 parent 06f1af4 commit 009eecf
Show file tree
Hide file tree
Showing 9 changed files with 108 additions and 163 deletions.
4 changes: 0 additions & 4 deletions Gruntfile.js
Expand Up @@ -53,10 +53,6 @@ module.exports = (grunt) => {
{
src: ['./less/index.less'],
dest: `${buildStaticPath}/css/index.css`
},
{
src: ['./less/indigo.less'],
dest: `${buildStaticPath}/css/indigo.css`
}
]
}
Expand Down
4 changes: 2 additions & 2 deletions igo/radiogroup/radiogroup.js
Expand Up @@ -4,7 +4,7 @@ function igoRadiogroup($) {

return {
preinit: function(el) {
this.getRadios(el).filter('[value=' + el.text() + ']').prop('checked', true);
this.getRadios(el).filter('[value="' + el.text() + '"]').prop('checked', true);
},

init: function(el, self) {
Expand Down Expand Up @@ -35,7 +35,7 @@ function igoRadiogroup($) {
},

getRadios: function(el) {
return $('[cid=radio]>label>input[name="' + el.attr('id') + '"]');
return $('[_=igoRadio]>label>input[name="' + el.attr('id') + '"]');
},

class: function(name, isAdd) {
Expand Down
4 changes: 2 additions & 2 deletions index.html
Expand Up @@ -23,8 +23,8 @@
DEBUG: false,
INFO: false,
contextPath: './build', //application URI
staticPath: '/static', //URI to static files (images, fonts, PDF, vendor files etc.)
componentPath: '/components', //URI to components source files
staticPath: '/static', //virtual path prefix to static files (images, fonts, PDF, vendor files etc.)
componentPath: '/components', //virtual path prefix to the components source files
};

function printSource(id) {
Expand Down
55 changes: 33 additions & 22 deletions js/loader.js
Expand Up @@ -2,7 +2,12 @@

(function(top) {
var ig = top.indigoJS = top.indigoJS || {},
console = window.console;
win = window, console = win.console;

win.indigoMain = function(callback) {
callback(win.$, win.indigoJS, win.indigoLocales);
};

ig.rootScope = ig.rootScope || {};
ig.wins = ig.wins || [];
ig.cssPath = ig.cssPath || function(uri, type, pkg, cls) {
Expand Down Expand Up @@ -74,7 +79,7 @@
el[key] = attrs[key];
}
el.onload = function() {
(onload || loadHandler)(url, type);
(onload || loadHandler)(url, type, el);
};
head.appendChild(el);
}
Expand Down Expand Up @@ -142,16 +147,20 @@
});
}
for (var j = 0; j < mains.length; j++) {
addAsset('script', {type: 'text/javascript', src: mains[j].value});
addAsset('script', {type: 'text/javascript', src: mains[j].value}, null, function(url, type, el) {
document.head.removeChild(el);
});
}
}
};

if (ig.wins.indexOf(window) === -1) {
ig.wins.push(window);
if (ig.wins.indexOf(win) === -1) {
ig.wins.push(win);
}
if (mains.length) {
addAsset('script', {type: 'text/javascript', src: ig.corePath(uri)});
addAsset('script', {type: 'text/javascript', src: ig.corePath(uri)}, null, function(url, type, el) {
document.head.removeChild(el);
});
}
addAsset('script', {type: 'text/javascript', src: ig.jqPath(uri)}, null, function(url, type) {
ig.wins.forEach(function(win) {
Expand All @@ -166,27 +175,29 @@
});
loadHandler(url, type);
if (ig.jqueryReady) {
ig.jqueryReady(window.$);
ig.jqueryReady(win.$);
}
});

libs.forEach(function(lib) {
var type = lib.replace('!', ''),
pair = type.split(/(?=[A-Z])/);
var pkg = pair[0],
cls = pair[1].toLowerCase();
if (loadedJs[type] === undefined) {
if (lib.charAt(0) !== '!') { //exclude script
loadedJs[type] = 0;
addAsset('script', {type: 'text/javascript', src: ig.jsPath(uri, type, pkg, cls)}, type);
if (lib.length) {
var type = lib.replace('!', ''),
pair = type.split(/(?=[A-Z])/);
var pkg = pair[0],
cls = pair[1].toLowerCase();
if (loadedJs[type] === undefined) {
if (lib.charAt(0) !== '!') { //exclude script
loadedJs[type] = 0;
addAsset('script', {type: 'text/javascript', src: ig.jsPath(uri, type, pkg, cls)}, type);
}
}
}
if (loadedCss[type] === undefined) {
if (lib.charAt(lib.length - 1) !== '!') { //exclude link
loadedCss[type] = 0;
addAsset('link', {rel: 'stylesheet', type: 'text/css', href: ig.cssPath(uri, type, pkg, cls)}, type);
} else {
loadedCss[type] = 1;
if (loadedCss[type] === undefined) {
if (lib.charAt(lib.length - 1) !== '!') { //exclude link
loadedCss[type] = 0;
addAsset('link', {rel: 'stylesheet', type: 'text/css', href: ig.cssPath(uri, type, pkg, cls)}, type);
} else {
loadedCss[type] = 1;
}
}
}
});
Expand Down
52 changes: 27 additions & 25 deletions less/common.less
Expand Up @@ -27,6 +27,33 @@ button, input, select, textarea {
font: inherit;
}

.clearfix::after {
display: block;
content: '';
clear: both;
}

.pull-right {
float: right!important;
}

.pull-left {
float: left!important;
}

.hide {
display: none!important;
}

.show {
display: block!important;
}

.container {
margin-right: auto;
margin-left: auto;
}

.headers();

c {
Expand Down Expand Up @@ -59,29 +86,4 @@ c[disabled] {

c.init {
opacity: 0 !important;
}

.headers() {
h1, h2, h3, h4, h5, h6 {
margin: 5px;
font-weight: 500;
}
h1 {
font-size: 2em;
}
h2 {
font-size: 1.5em;
}
h3 {
font-size: 1.33em;
}
h4 {
font-size: 1.17em;
}
h5 {
font-size: 0.83em;
}
h6 {
font-size: 0.67em;
}
}
40 changes: 40 additions & 0 deletions less/constant.less
Expand Up @@ -95,4 +95,44 @@

.disabledColor() {
color: #aaa !important;
}

.headers() {
h1, h2, h3, h4, h5, h6 {
margin: 5px;
font-weight: 500;
}
h1 {
font-size: 2em;
}
h2 {
font-size: 1.5em;
}
h3 {
font-size: 1.33em;
}
h4 {
font-size: 1.17em;
}
h5 {
font-size: 0.83em;
}
h6 {
font-size: 0.67em;
}
}

.widthLoop(@clsName: '.col-', @total: 12) {
@prefix: ~"@{clsName}";
@width: 100 / @total;

.loop (@i) when (@i <= @total) {
@{prefix}@{i} {
width: unit(@width * @i, %);
}

.loop(@i + 1);
}

.loop(1);
}
2 changes: 1 addition & 1 deletion less/index.less
Expand Up @@ -23,7 +23,7 @@ body {
font-weight: bold;
}

[cid=menu] {
[_=igoMenu] {
height: 100%;
border: 1px #fff;
border-left-style: solid;
Expand Down
104 changes: 0 additions & 104 deletions less/indigo.less

This file was deleted.

6 changes: 3 additions & 3 deletions package.json
@@ -1,9 +1,9 @@
{
"name": "indigojs-components",
"version": "v3.5.5",
"version": "v3.5.6",
"config": {
"old_tag": "v3.5.4",
"new_tag": "v3.5.5"
"old_tag": "v3.5.5",
"new_tag": "v3.5.6"
},
"scripts": {
"start": "node server.js",
Expand Down

0 comments on commit 009eecf

Please sign in to comment.