Skip to content

Commit aaf9d83

Browse files
committed
更新package.json
1 parent 5ec722e commit aaf9d83

10 files changed

+61
-65
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ doc
77
*.iml
88
yarn.lock
99
package-lock.json
10-
dist
10+
dist/

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@ jQuery plugin offering an simple interface to create complex queries.
2727
#### With Bower
2828

2929
```bash
30-
$ bower install jQuery-QueryBuilder
30+
$ bower install @duotai/jquery-querybuilder
3131
```
3232

3333
#### With npm
3434

3535
```bash
36-
$ npm install jQuery-QueryBuilder
36+
$ npm i @duotai/jquery-querybuilder
3737
```
3838

3939
#### Via CDN

dist/css/query-builder.default.css

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,3 +171,7 @@
171171
border: 1px dashed #BBB;
172172
opacity: .7;
173173
}
174+
175+
button.btn{
176+
border: 1px solid #000;
177+
}

dist/js/query-builder.js

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -429,12 +429,12 @@ QueryBuilder.DEFAULTS = {
429429
'is_not_null'
430430
],
431431

432-
icons: {
433-
add_group: 'glyphicon glyphicon-plus-sign',
434-
add_rule: 'glyphicon glyphicon-plus',
435-
remove_group: 'glyphicon glyphicon-remove',
436-
remove_rule: 'glyphicon glyphicon-remove',
437-
error: 'glyphicon glyphicon-warning-sign'
432+
icons: {
433+
add_group: 'fas fa-plus-circle',
434+
add_rule: 'fas fa-plus',
435+
remove_group: 'fas fa-times',
436+
remove_rule: 'fas fa-times',
437+
error: 'fas fa-exclamation-triangle'
438438
}
439439
};
440440

@@ -2680,26 +2680,26 @@ QueryBuilder.prototype.getValidationMessage = function(validation, type, def) {
26802680

26812681

26822682
QueryBuilder.templates.group = '\
2683-
<div id="{{= it.group_id }}" class="rules-group-container"> \
2683+
<div id="{{= it.group_id }}" class="rules-group-container w-100"> \
26842684
<div class="rules-group-header"> \
2685-
<div class="btn-group pull-right group-actions"> \
2686-
<button type="button" class="btn btn-xs btn-success" data-add="rule"> \
2685+
<div class="btn-group float-right group-actions"> \
2686+
<button type="button" class="btn btn-sm btn-success" data-add="rule"> \
26872687
<i class="{{= it.icons.add_rule }}"></i> {{= it.translate("add_rule") }} \
26882688
</button> \
26892689
{{? it.settings.allow_groups===-1 || it.settings.allow_groups>=it.level }} \
2690-
<button type="button" class="btn btn-xs btn-success" data-add="group"> \
2690+
<button type="button" class="btn btn-sm btn-success" data-add="group"> \
26912691
<i class="{{= it.icons.add_group }}"></i> {{= it.translate("add_group") }} \
26922692
</button> \
26932693
{{?}} \
26942694
{{? it.level>1 }} \
2695-
<button type="button" class="btn btn-xs btn-danger" data-delete="group"> \
2695+
<button type="button" class="btn btn-sm btn-danger" data-delete="group"> \
26962696
<i class="{{= it.icons.remove_group }}"></i> {{= it.translate("delete_group") }} \
26972697
</button> \
26982698
{{?}} \
26992699
</div> \
27002700
<div class="btn-group group-conditions"> \
27012701
{{~ it.conditions: condition }} \
2702-
<label class="btn btn-xs btn-primary"> \
2702+
<label class="btn btn-sm btn-primary"> \
27032703
<input type="radio" name="{{= it.group_id }}_cond" value="{{= condition }}"> {{= it.translate("conditions", condition) }} \
27042704
</label> \
27052705
{{~}} \
@@ -2716,8 +2716,8 @@ QueryBuilder.templates.group = '\
27162716
QueryBuilder.templates.rule = '\
27172717
<div id="{{= it.rule_id }}" class="rule-container"> \
27182718
<div class="rule-header"> \
2719-
<div class="btn-group pull-right rule-actions"> \
2720-
<button type="button" class="btn btn-xs btn-danger" data-delete="rule"> \
2719+
<div class="btn-group float-right rule-actions"> \
2720+
<button type="button" class="btn btn-sm btn-danger" data-delete="rule"> \
27212721
<i class="{{= it.icons.remove_rule }}"></i> {{= it.translate("delete_rule") }} \
27222722
</button> \
27232723
</div> \
@@ -3957,7 +3957,7 @@ QueryBuilder.define('bt-checkbox', function(options) {
39573957
* @descriptioon Applies Bootstrap Select on filters and operators combo-boxes.
39583958
* @param {object} [options]
39593959
* @param {string} [options.container='body']
3960-
* @param {string} [options.style='btn-inverse btn-xs']
3960+
* @param {string} [options.style='btn-inverse btn-sm']
39613961
* @param {int|string} [options.width='auto']
39623962
* @param {boolean} [options.showIcon=false]
39633963
* @throws MissingLibraryError
@@ -4305,7 +4305,7 @@ QueryBuilder.define('filter-description', function(options) {
43054305
}
43064306
else {
43074307
if ($b.length === 0) {
4308-
$b = $($.parseHTML('<button type="button" class="btn btn-xs btn-info filter-description" data-toggle="popover"><i class="' + options.icon + '"></i></button>'));
4308+
$b = $($.parseHTML('<button type="button" class="btn btn-sm btn-info filter-description" data-toggle="popover"><i class="' + options.icon + '"></i></button>'));
43094309
$b.prependTo(rule.$el.find(QueryBuilder.selectors.rule_actions));
43104310

43114311
$b.popover({
@@ -4345,7 +4345,7 @@ QueryBuilder.define('filter-description', function(options) {
43454345
}
43464346
else {
43474347
if ($b.length === 0) {
4348-
$b = $($.parseHTML('<button type="button" class="btn btn-xs btn-info filter-description" data-toggle="bootbox"><i class="' + options.icon + '"></i></button>'));
4348+
$b = $($.parseHTML('<button type="button" class="btn btn-sm btn-info filter-description" data-toggle="bootbox"><i class="' + options.icon + '"></i></button>'));
43494349
$b.prependTo(rule.$el.find(QueryBuilder.selectors.rule_actions));
43504350

43514351
$b.on('click', function() {
@@ -4422,7 +4422,7 @@ QueryBuilder.define('invert', function(options) {
44224422
this.on('getGroupTemplate.filter', function(h) {
44234423
var $h = $($.parseHTML(h.value));
44244424
$h.find(Selectors.condition_container).after(
4425-
'<button type="button" class="btn btn-xs btn-default" data-invert="group">' +
4425+
'<button type="button" class="btn btn-sm btn-default" data-invert="group">' +
44264426
'<i class="' + options.icon + '"></i> ' + self.translate('invert') +
44274427
'</button>'
44284428
);
@@ -4433,7 +4433,7 @@ QueryBuilder.define('invert', function(options) {
44334433
this.on('getRuleTemplate.filter', function(h) {
44344434
var $h = $($.parseHTML(h.value));
44354435
$h.find(Selectors.rule_actions).prepend(
4436-
'<button type="button" class="btn btn-xs btn-default" data-invert="rule">' +
4436+
'<button type="button" class="btn btn-sm btn-default" data-invert="rule">' +
44374437
'<i class="' + options.icon + '"></i> ' + self.translate('invert') +
44384438
'</button>'
44394439
);
@@ -4985,7 +4985,7 @@ QueryBuilder.define('not-group', function(options) {
49854985
this.on('getGroupTemplate.filter', function(h) {
49864986
var $h = $($.parseHTML(h.value));
49874987
$h.find(QueryBuilder.selectors.condition_container).prepend(
4988-
'<button type="button" class="btn btn-xs btn-default" data-not="group">' +
4988+
'<button type="button" class="btn btn-sm btn-default" data-not="group">' +
49894989
'<i class="' + options.icon_unchecked + '"></i> ' + self.translate('NOT') +
49904990
'</button>'
49914991
);

dist/js/query-builder.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/js/query-builder.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/js/query-builder.standalone.js

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -709,12 +709,12 @@ QueryBuilder.DEFAULTS = {
709709
'is_not_null'
710710
],
711711

712-
icons: {
713-
add_group: 'glyphicon glyphicon-plus-sign',
714-
add_rule: 'glyphicon glyphicon-plus',
715-
remove_group: 'glyphicon glyphicon-remove',
716-
remove_rule: 'glyphicon glyphicon-remove',
717-
error: 'glyphicon glyphicon-warning-sign'
712+
icons: {
713+
add_group: 'fas fa-plus-circle',
714+
add_rule: 'fas fa-plus',
715+
remove_group: 'fas fa-times',
716+
remove_rule: 'fas fa-times',
717+
error: 'fas fa-exclamation-triangle'
718718
}
719719
};
720720

@@ -2960,26 +2960,26 @@ QueryBuilder.prototype.getValidationMessage = function(validation, type, def) {
29602960

29612961

29622962
QueryBuilder.templates.group = '\
2963-
<div id="{{= it.group_id }}" class="rules-group-container"> \
2963+
<div id="{{= it.group_id }}" class="rules-group-container w-100"> \
29642964
<div class="rules-group-header"> \
2965-
<div class="btn-group pull-right group-actions"> \
2966-
<button type="button" class="btn btn-xs btn-success" data-add="rule"> \
2965+
<div class="btn-group float-right group-actions"> \
2966+
<button type="button" class="btn btn-sm btn-success" data-add="rule"> \
29672967
<i class="{{= it.icons.add_rule }}"></i> {{= it.translate("add_rule") }} \
29682968
</button> \
29692969
{{? it.settings.allow_groups===-1 || it.settings.allow_groups>=it.level }} \
2970-
<button type="button" class="btn btn-xs btn-success" data-add="group"> \
2970+
<button type="button" class="btn btn-sm btn-success" data-add="group"> \
29712971
<i class="{{= it.icons.add_group }}"></i> {{= it.translate("add_group") }} \
29722972
</button> \
29732973
{{?}} \
29742974
{{? it.level>1 }} \
2975-
<button type="button" class="btn btn-xs btn-danger" data-delete="group"> \
2975+
<button type="button" class="btn btn-sm btn-danger" data-delete="group"> \
29762976
<i class="{{= it.icons.remove_group }}"></i> {{= it.translate("delete_group") }} \
29772977
</button> \
29782978
{{?}} \
29792979
</div> \
29802980
<div class="btn-group group-conditions"> \
29812981
{{~ it.conditions: condition }} \
2982-
<label class="btn btn-xs btn-primary"> \
2982+
<label class="btn btn-sm btn-primary"> \
29832983
<input type="radio" name="{{= it.group_id }}_cond" value="{{= condition }}"> {{= it.translate("conditions", condition) }} \
29842984
</label> \
29852985
{{~}} \
@@ -2996,8 +2996,8 @@ QueryBuilder.templates.group = '\
29962996
QueryBuilder.templates.rule = '\
29972997
<div id="{{= it.rule_id }}" class="rule-container"> \
29982998
<div class="rule-header"> \
2999-
<div class="btn-group pull-right rule-actions"> \
3000-
<button type="button" class="btn btn-xs btn-danger" data-delete="rule"> \
2999+
<div class="btn-group float-right rule-actions"> \
3000+
<button type="button" class="btn btn-sm btn-danger" data-delete="rule"> \
30013001
<i class="{{= it.icons.remove_rule }}"></i> {{= it.translate("delete_rule") }} \
30023002
</button> \
30033003
</div> \
@@ -4237,7 +4237,7 @@ QueryBuilder.define('bt-checkbox', function(options) {
42374237
* @descriptioon Applies Bootstrap Select on filters and operators combo-boxes.
42384238
* @param {object} [options]
42394239
* @param {string} [options.container='body']
4240-
* @param {string} [options.style='btn-inverse btn-xs']
4240+
* @param {string} [options.style='btn-inverse btn-sm']
42414241
* @param {int|string} [options.width='auto']
42424242
* @param {boolean} [options.showIcon=false]
42434243
* @throws MissingLibraryError
@@ -4585,7 +4585,7 @@ QueryBuilder.define('filter-description', function(options) {
45854585
}
45864586
else {
45874587
if ($b.length === 0) {
4588-
$b = $($.parseHTML('<button type="button" class="btn btn-xs btn-info filter-description" data-toggle="popover"><i class="' + options.icon + '"></i></button>'));
4588+
$b = $($.parseHTML('<button type="button" class="btn btn-sm btn-info filter-description" data-toggle="popover"><i class="' + options.icon + '"></i></button>'));
45894589
$b.prependTo(rule.$el.find(QueryBuilder.selectors.rule_actions));
45904590

45914591
$b.popover({
@@ -4625,7 +4625,7 @@ QueryBuilder.define('filter-description', function(options) {
46254625
}
46264626
else {
46274627
if ($b.length === 0) {
4628-
$b = $($.parseHTML('<button type="button" class="btn btn-xs btn-info filter-description" data-toggle="bootbox"><i class="' + options.icon + '"></i></button>'));
4628+
$b = $($.parseHTML('<button type="button" class="btn btn-sm btn-info filter-description" data-toggle="bootbox"><i class="' + options.icon + '"></i></button>'));
46294629
$b.prependTo(rule.$el.find(QueryBuilder.selectors.rule_actions));
46304630

46314631
$b.on('click', function() {
@@ -4702,7 +4702,7 @@ QueryBuilder.define('invert', function(options) {
47024702
this.on('getGroupTemplate.filter', function(h) {
47034703
var $h = $($.parseHTML(h.value));
47044704
$h.find(Selectors.condition_container).after(
4705-
'<button type="button" class="btn btn-xs btn-default" data-invert="group">' +
4705+
'<button type="button" class="btn btn-sm btn-default" data-invert="group">' +
47064706
'<i class="' + options.icon + '"></i> ' + self.translate('invert') +
47074707
'</button>'
47084708
);
@@ -4713,7 +4713,7 @@ QueryBuilder.define('invert', function(options) {
47134713
this.on('getRuleTemplate.filter', function(h) {
47144714
var $h = $($.parseHTML(h.value));
47154715
$h.find(Selectors.rule_actions).prepend(
4716-
'<button type="button" class="btn btn-xs btn-default" data-invert="rule">' +
4716+
'<button type="button" class="btn btn-sm btn-default" data-invert="rule">' +
47174717
'<i class="' + options.icon + '"></i> ' + self.translate('invert') +
47184718
'</button>'
47194719
);
@@ -5265,7 +5265,7 @@ QueryBuilder.define('not-group', function(options) {
52655265
this.on('getGroupTemplate.filter', function(h) {
52665266
var $h = $($.parseHTML(h.value));
52675267
$h.find(QueryBuilder.selectors.condition_container).prepend(
5268-
'<button type="button" class="btn btn-xs btn-default" data-not="group">' +
5268+
'<button type="button" class="btn btn-sm btn-default" data-not="group">' +
52695269
'<i class="' + options.icon_unchecked + '"></i> ' + self.translate('NOT') +
52705270
'</button>'
52715271
);

dist/js/query-builder.standalone.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/js/query-builder.standalone.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 10 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,10 @@
11
{
2-
"name": "jQuery-QueryBuilder",
3-
"version": "2.6.0",
4-
"author": {
5-
"name": "Damien \"Mistic\" Sorel",
6-
"email": "contact@git.strangeplanet.fr",
7-
"url": "https://www.strangeplanet.fr"
8-
},
9-
"description": "jQuery plugin for user friendly query/filter creator",
2+
"name": "@duotai/jquery-querybuilder",
3+
"version": "1.0.3",
4+
"description": "jQuery plugin for user friendly query/filter creator, Bootstrap 4 Compatibility.",
105
"main": "dist/js/query-builder.js",
11-
"files": [
12-
"dist/",
13-
"src/"
14-
],
6+
"author": "dt-zhaozc",
157
"dependencies": {
16-
"@popperjs/core": "^2.9.3",
178
"bootstrap": "^4.6.0",
189
"dot": "^1.1.3",
1910
"jquery": "^3.5.1",
@@ -59,20 +50,21 @@
5950
"selectize": "^0.12.4",
6051
"time-grunt": "^1.3.0"
6152
},
53+
"files": [
54+
"dist/",
55+
"src/"
56+
],
57+
"homepage": "https://querybuilder.js.org",
6258
"keywords": [
6359
"jquery",
6460
"query",
6561
"builder",
6662
"filter"
6763
],
6864
"license": "MIT",
69-
"homepage": "https://querybuilder.js.org",
7065
"repository": {
7166
"type": "git",
72-
"url": "git://github.com/mistic100/jQuery-QueryBuilder.git"
73-
},
74-
"bugs": {
75-
"url": "https://github.com/mistic100/jQuery-QueryBuilder/issues"
67+
"url": "https://github.com/gdlcf88/jQuery-QueryBuilder"
7668
},
7769
"scripts": {
7870
"build": "grunt",

0 commit comments

Comments
 (0)