Skip to content

Commit

Permalink
Timepicker: added attributes data-cls-button, data-cls-ok-button,…
Browse files Browse the repository at this point in the history
… `data-cls-cancel-button` to modify picker buttons style, issue #1659
  • Loading branch information
olton committed Nov 6, 2020
1 parent 9ad7686 commit e58ff73
Show file tree
Hide file tree
Showing 35 changed files with 53 additions and 43 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
+ [x] i18n: added `tr-TR` turkish locale.
+ [x] Third party plugins: removed support for `select2`, `datatables`
+ [x] AppBar: added event `onBeforeMenuOpen`, `onBeforeMenuClose`, fixed firing events `onMenuOpen`, `onMenuClose`.
+ [x] Timepicker: added attributes `data-cls-button`, `data-cls-ok-button`, `data-cls-cancel-button` to modify picker buttons style, issue #1659.

### 4.4.1
#### M4Q
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ In addition, **SUPPORT PACK** is available for an annual subscription on [XS:COD

### Donation on Patreon
![Donations on Patreon](https://img.shields.io/badge/Patrons-7-green.svg)
![Donations on Patreon](https://img.shields.io/badge/Donation-$130-red.svg)
![Donations on Patreon](https://img.shields.io/badge/Donation-$140-red.svg)

### Community

Expand Down
2 changes: 1 addition & 1 deletion build/css/metro-all.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
*,
Expand Down
2 changes: 1 addition & 1 deletion build/css/metro-animations.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
2 changes: 1 addition & 1 deletion build/css/metro-colors.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-transparent {
Expand Down
2 changes: 1 addition & 1 deletion build/css/metro-common.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.button.primary,
Expand Down
2 changes: 1 addition & 1 deletion build/css/metro-components.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.accordion {
Expand Down
2 changes: 1 addition & 1 deletion build/css/metro-icons.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
@font-face {
Expand Down
2 changes: 1 addition & 1 deletion build/css/metro-reset.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
*,
Expand Down
2 changes: 1 addition & 1 deletion build/css/metro.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
*,
Expand Down
2 changes: 1 addition & 1 deletion build/css/schemes/darcula.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
2 changes: 1 addition & 1 deletion build/css/schemes/red-alert.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
2 changes: 1 addition & 1 deletion build/css/schemes/red-dark.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
2 changes: 1 addition & 1 deletion build/css/schemes/red-mirohost.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
2 changes: 1 addition & 1 deletion build/css/schemes/sky-net.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
11 changes: 7 additions & 4 deletions build/js/metro.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
(function (global, undefined) {
Expand Down Expand Up @@ -4537,7 +4537,7 @@ $.noConflict = function() {
var Metro = {

version: "4.4.2",
compileTime: "05/11/2020 16:19:38",
compileTime: "06/11/2020 11:27:03",
buildNumber: "@@build",
isTouchable: isTouch,
fullScreenEnabled: document.fullscreenEnabled,
Expand Down Expand Up @@ -31275,6 +31275,9 @@ $.noConflict = function() {
clsMinutes: "",
clsSeconds: "",
clsLabel: "",
clsButton: "",
clsOkButton: "",
clsCancelButton: "",
okButtonIcon: "<span class='default-icon-check'></span>",
cancelButtonIcon: "<span class='default-icon-cross'></span>",
onSet: Metro.noop,
Expand Down Expand Up @@ -31436,8 +31439,8 @@ $.noConflict = function() {
selectBlock.height((o.distance * 2 + 1) * 40);

actionBlock = $("<div>").addClass("action-block").appendTo(selectWrapper);
$("<button>").attr("type", "button").addClass("button action-ok").html(o.okButtonIcon).appendTo(actionBlock);
$("<button>").attr("type", "button").addClass("button action-cancel").html(o.cancelButtonIcon).appendTo(actionBlock);
$("<button>").attr("type", "button").addClass("button action-ok").addClass(o.clsButton).addClass(o.clsOkButton).html(o.okButtonIcon).appendTo(actionBlock);
$("<button>").attr("type", "button").addClass("button action-cancel").addClass(o.clsButton).addClass(o.clsCancelButton).html(o.cancelButtonIcon).appendTo(actionBlock);


element[0].className = '';
Expand Down
4 changes: 2 additions & 2 deletions build/js/metro.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion build/js/metro.min.js.map

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions source/components/timepicker/timepicker.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
clsMinutes: "",
clsSeconds: "",
clsLabel: "",
clsButton: "",
clsOkButton: "",
clsCancelButton: "",
okButtonIcon: "<span class='default-icon-check'></span>",
cancelButtonIcon: "<span class='default-icon-cross'></span>",
onSet: Metro.noop,
Expand Down Expand Up @@ -184,8 +187,8 @@
selectBlock.height((o.distance * 2 + 1) * 40);

actionBlock = $("<div>").addClass("action-block").appendTo(selectWrapper);
$("<button>").attr("type", "button").addClass("button action-ok").html(o.okButtonIcon).appendTo(actionBlock);
$("<button>").attr("type", "button").addClass("button action-cancel").html(o.cancelButtonIcon).appendTo(actionBlock);
$("<button>").attr("type", "button").addClass("button action-ok").addClass(o.clsButton).addClass(o.clsOkButton).html(o.okButtonIcon).appendTo(actionBlock);
$("<button>").attr("type", "button").addClass("button action-cancel").addClass(o.clsButton).addClass(o.clsCancelButton).html(o.cancelButtonIcon).appendTo(actionBlock);


element[0].className = '';
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/metro-all.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
*,
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/metro-animations.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
2 changes: 1 addition & 1 deletion tests/metro/css/metro-colors.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-transparent {
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/metro-common.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.button.primary,
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/metro-components.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.accordion {
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/metro-icons.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
@font-face {
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/metro-reset.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
*,
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/metro.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
*,
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/schemes/darcula.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/schemes/red-alert.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/schemes/red-dark.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/schemes/red-mirohost.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
2 changes: 1 addition & 1 deletion tests/metro/css/schemes/sky-net.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
.bg-scheme {
Expand Down
11 changes: 7 additions & 4 deletions tests/metro/js/metro.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* Metro 4 Components Library v4.4.2 (https://metroui.org.ua)
* Copyright 2012-2020 Sergey Pimenov
* Built at 05/11/2020 16:19:38
* Built at 06/11/2020 11:27:03
* Licensed under MIT
*/
(function (global, undefined) {
Expand Down Expand Up @@ -4537,7 +4537,7 @@ $.noConflict = function() {
var Metro = {

version: "4.4.2",
compileTime: "05/11/2020 16:19:38",
compileTime: "06/11/2020 11:27:03",
buildNumber: "@@build",
isTouchable: isTouch,
fullScreenEnabled: document.fullscreenEnabled,
Expand Down Expand Up @@ -31275,6 +31275,9 @@ $.noConflict = function() {
clsMinutes: "",
clsSeconds: "",
clsLabel: "",
clsButton: "",
clsOkButton: "",
clsCancelButton: "",
okButtonIcon: "<span class='default-icon-check'></span>",
cancelButtonIcon: "<span class='default-icon-cross'></span>",
onSet: Metro.noop,
Expand Down Expand Up @@ -31436,8 +31439,8 @@ $.noConflict = function() {
selectBlock.height((o.distance * 2 + 1) * 40);

actionBlock = $("<div>").addClass("action-block").appendTo(selectWrapper);
$("<button>").attr("type", "button").addClass("button action-ok").html(o.okButtonIcon).appendTo(actionBlock);
$("<button>").attr("type", "button").addClass("button action-cancel").html(o.cancelButtonIcon).appendTo(actionBlock);
$("<button>").attr("type", "button").addClass("button action-ok").addClass(o.clsButton).addClass(o.clsOkButton).html(o.okButtonIcon).appendTo(actionBlock);
$("<button>").attr("type", "button").addClass("button action-cancel").addClass(o.clsButton).addClass(o.clsCancelButton).html(o.cancelButtonIcon).appendTo(actionBlock);


element[0].className = '';
Expand Down
4 changes: 2 additions & 2 deletions tests/metro/js/metro.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion tests/metro/js/metro.min.js.map

Large diffs are not rendered by default.

0 comments on commit e58ff73

Please sign in to comment.