Skip to content

Commit

Permalink
chore(all): dist build
Browse files Browse the repository at this point in the history
  • Loading branch information
Thanood committed Apr 18, 2016
1 parent cd463c1 commit 6621c58
Show file tree
Hide file tree
Showing 46 changed files with 655 additions and 387 deletions.
32 changes: 18 additions & 14 deletions dist/amd/aurelia-materialize-bridge.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,17 +108,6 @@ declare module 'aurelia-materialize-bridge' {
attached(): any;
detached(): any;
}

// taken from: https://github.com/heruan/aurelia-breadcrumbs
export class MdBreadcrumbs {
constructor(element: any, router: any);
navigate(navigationInstruction: any): any;
}

// this.router.navigate(navigationInstruction.config.name);
export class InstructionFilterValueConverter {
toView(navigationInstructions: any): any;
}
export class MdButton {
disabled: any;
flat: any;
Expand All @@ -130,6 +119,17 @@ declare module 'aurelia-materialize-bridge' {
disabledChanged(newValue: any): any;
flatChanged(newValue: any): any;
}

// taken from: https://github.com/heruan/aurelia-breadcrumbs
export class MdBreadcrumbs {
constructor(element: any, router: any);
navigate(navigationInstruction: any): any;
}

// this.router.navigate(navigationInstruction.config.name);
export class InstructionFilterValueConverter {
toView(navigationInstructions: any): any;
}
export class MdCard {
mdImage: any;
mdReveal: any;
Expand Down Expand Up @@ -180,11 +180,15 @@ declare module 'aurelia-materialize-bridge' {
refresh(): any;
accordionChanged(): any;
}
export class MdCollectionHeader {
constructor(element: any);
}
export class MdCollectionItem {

}
export class MdCollection {
constructor(element: any);
attached(): any;
getSelected(): any;
}
export class MdlListSelector {
Expand Down Expand Up @@ -534,6 +538,9 @@ declare module 'aurelia-materialize-bridge' {
// FIXME: probably bad
selectedTab: any;
}
export class MdToastService {
show(message: any, displayLength: any, className?: any): any;
}

// @customAttribute('md-tooltip')
export class MdTooltip {
Expand All @@ -544,9 +551,6 @@ declare module 'aurelia-materialize-bridge' {
attached(): any;
detached(): any;
}
export class MdToastService {
show(message: any, displayLength: any, className?: any): any;
}
export class MdFadeinImage {
ref: any;
constructor(element: any);
Expand Down
3 changes: 3 additions & 0 deletions dist/amd/collection/collection-header.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
md-collection-header {
display: block;
}
4 changes: 4 additions & 0 deletions dist/amd/collection/collection-header.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<template class="collection-header">
<require from="./collection-header.css"></require>
<content></content>
</template>
22 changes: 22 additions & 0 deletions dist/amd/collection/collection-header.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
define(['exports', 'aurelia-templating', 'aurelia-dependency-injection'], function (exports, _aureliaTemplating, _aureliaDependencyInjection) {
'use strict';

Object.defineProperty(exports, "__esModule", {
value: true
});
exports.MdCollectionHeader = undefined;

function _classCallCheck(instance, Constructor) {
if (!(instance instanceof Constructor)) {
throw new TypeError("Cannot call a class as a function");
}
}

var _dec, _dec2, _class;

var MdCollectionHeader = exports.MdCollectionHeader = (_dec = (0, _aureliaTemplating.customElement)('md-collection-header'), _dec2 = (0, _aureliaDependencyInjection.inject)(Element), _dec(_class = _dec2(_class = function MdCollectionHeader(element) {
_classCallCheck(this, MdCollectionHeader);

this.element = element;
}) || _class) || _class);
});
3 changes: 2 additions & 1 deletion dist/amd/collection/collection.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<template>
<div class="collection">
<div class="collection" ref="anchor">
<content select="md-collection-header"></content>
<content select="md-collection-item"></content>
</div>
</template>
7 changes: 7 additions & 0 deletions dist/amd/collection/collection.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@ define(['exports', 'aurelia-templating', 'aurelia-dependency-injection'], functi
this.element = element;
}

MdCollection.prototype.attached = function attached() {
var header = this.element.querySelector('md-collection-header');
if (header) {
this.anchor.classList.add('with-header');
}
};

MdCollection.prototype.getSelected = function getSelected() {
var items = [].slice.call(this.element.querySelectorAll('md-collection-selector'));
return items.filter(function (i) {
Expand Down
9 changes: 7 additions & 2 deletions dist/amd/colors/md-colors.html
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,10 @@
background-color: ${mdPrimaryColor | lighten:0.5};
transition: .2s ease-out;
}
.btn-flat:hover {
.btn-flat:not(.disabled):hover {
/*background-color: ${mdAccentColor | lighten:3};*/
background-color: transparent;
background-color: rgba(50, 50, 50, .15);
box-shadow: 0 5px 11px 0 rgba(0, 0, 0, 0.18), 0 4px 15px 0 rgba(0, 0, 0, 0.15);
border: none;
box-shadow: none;
transition: .2s ease-out;
Expand Down Expand Up @@ -104,6 +105,10 @@
color: white;
}

md-collection .collection md-collection-item.collection-item .secondary-content {
color: ${mdAccentColor};
}

/* datepicker */
.picker__date-display {
background-color: ${mdAccentColor};
Expand Down
1 change: 1 addition & 0 deletions dist/amd/config-builder.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ define(['exports'], function (exports) {
ConfigBuilder.prototype.useCollection = function useCollection() {
this.globalResources.push('./collection/collection');
this.globalResources.push('./collection/collection-item');
this.globalResources.push('./collection/collection-header');
this.globalResources.push('./collection/md-collection-selector');
return this;
};
Expand Down
32 changes: 18 additions & 14 deletions dist/aurelia-materialize-bridge.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,17 +108,6 @@ declare module 'aurelia-materialize-bridge' {
attached(): any;
detached(): any;
}

// taken from: https://github.com/heruan/aurelia-breadcrumbs
export class MdBreadcrumbs {
constructor(element: any, router: any);
navigate(navigationInstruction: any): any;
}

// this.router.navigate(navigationInstruction.config.name);
export class InstructionFilterValueConverter {
toView(navigationInstructions: any): any;
}
export class MdButton {
disabled: any;
flat: any;
Expand All @@ -130,6 +119,17 @@ declare module 'aurelia-materialize-bridge' {
disabledChanged(newValue: any): any;
flatChanged(newValue: any): any;
}

// taken from: https://github.com/heruan/aurelia-breadcrumbs
export class MdBreadcrumbs {
constructor(element: any, router: any);
navigate(navigationInstruction: any): any;
}

// this.router.navigate(navigationInstruction.config.name);
export class InstructionFilterValueConverter {
toView(navigationInstructions: any): any;
}
export class MdCard {
mdImage: any;
mdReveal: any;
Expand Down Expand Up @@ -180,11 +180,15 @@ declare module 'aurelia-materialize-bridge' {
refresh(): any;
accordionChanged(): any;
}
export class MdCollectionHeader {
constructor(element: any);
}
export class MdCollectionItem {

}
export class MdCollection {
constructor(element: any);
attached(): any;
getSelected(): any;
}
export class MdlListSelector {
Expand Down Expand Up @@ -534,6 +538,9 @@ declare module 'aurelia-materialize-bridge' {
// FIXME: probably bad
selectedTab: any;
}
export class MdToastService {
show(message: any, displayLength: any, className?: any): any;
}

// @customAttribute('md-tooltip')
export class MdTooltip {
Expand All @@ -544,9 +551,6 @@ declare module 'aurelia-materialize-bridge' {
attached(): any;
detached(): any;
}
export class MdToastService {
show(message: any, displayLength: any, className?: any): any;
}
export class MdFadeinImage {
ref: any;
constructor(element: any);
Expand Down
100 changes: 58 additions & 42 deletions dist/aurelia-materialize-bridge.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ export class ConfigBuilder {
useCollection() : ConfigBuilder {
this.globalResources.push('./collection/collection');
this.globalResources.push('./collection/collection-item');
this.globalResources.push('./collection/collection-header');
this.globalResources.push('./collection/md-collection-selector');
return this;
}
Expand Down Expand Up @@ -355,38 +356,6 @@ export class MdBox {
}
}

// taken from: https://github.com/heruan/aurelia-breadcrumbs

@customElement('md-breadcrumbs')
@inject(Element, Router)
export class MdBreadcrumbs {
constructor(element, router) {
this.element = element;
this._childRouter = router;
while (router.parent) {
router = router.parent;
}
this.router = router;
}

navigate(navigationInstruction) {
this._childRouter.navigateToRoute(navigationInstruction.config.name);
// this.router.navigate(navigationInstruction.config.name);
}
}

export class InstructionFilterValueConverter {
toView(navigationInstructions) {
return navigationInstructions.filter(i => {
let result = false;
if (i.config.title) {
result = true;
}
return result;
});
}
}

@customAttribute('md-button')
@inject(Element)
export class MdButton {
Expand Down Expand Up @@ -449,6 +418,38 @@ export class MdButton {
}
}

// taken from: https://github.com/heruan/aurelia-breadcrumbs

@customElement('md-breadcrumbs')
@inject(Element, Router)
export class MdBreadcrumbs {
constructor(element, router) {
this.element = element;
this._childRouter = router;
while (router.parent) {
router = router.parent;
}
this.router = router;
}

navigate(navigationInstruction) {
this._childRouter.navigateToRoute(navigationInstruction.config.name);
// this.router.navigate(navigationInstruction.config.name);
}
}

export class InstructionFilterValueConverter {
toView(navigationInstructions) {
return navigationInstructions.filter(i => {
let result = false;
if (i.config.title) {
result = true;
}
return result;
});
}
}

@customElement('md-card')
@inject(Element)
export class MdCard {
Expand Down Expand Up @@ -652,6 +653,14 @@ export class MdCollapsible {
}
}
@customElement('md-collection-header')
@inject(Element)
export class MdCollectionHeader {
constructor(element) {
this.element = element;
}
}
@customElement('md-collection-item')
export class MdCollectionItem { }
Expand All @@ -662,6 +671,13 @@ export class MdCollection {
this.element = element;
}
attached() {
let header = this.element.querySelector('md-collection-header');
if (header) {
this.anchor.classList.add('with-header');
}
}
getSelected() {
let items = [].slice.call(this.element.querySelectorAll('md-collection-selector'));
return items.filter(i => i.au['md-collection-selector'].viewModel.isSelected)
Expand Down Expand Up @@ -1887,6 +1903,16 @@ export class MdTabs {
}
}

export class MdToastService {
show(message, displayLength, className?) {
return new Promise((resolve, reject) => {
Materialize.toast(message, displayLength, className, () => {
resolve();
});
});
}
}

// @customAttribute('md-tooltip')
@inject(Element)
export class MdTooltip {
Expand All @@ -1912,16 +1938,6 @@ export class MdTooltip {
}
}
export class MdToastService {
show(message, displayLength, className?) {
return new Promise((resolve, reject) => {
Materialize.toast(message, displayLength, className, () => {
resolve();
});
});
}
}
@customAttribute('md-fadein-image')
@inject(Element)
export class MdFadeinImage {
Expand Down
Loading

0 comments on commit 6621c58

Please sign in to comment.