gd-bs 6.7.7 → 6.7.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/bs.js +1 -1
- package/build/components/floating-ui/index.js +4 -1
- package/build/components/tooltip/index.js +2 -0
- package/dist/gd-bs-icons.js +1 -1
- package/dist/gd-bs-icons.min.js +1 -1
- package/dist/gd-bs.js +1 -1
- package/dist/gd-bs.min.js +1 -1
- package/indexv2.html +56 -31
- package/package.json +60 -60
- package/src/components/floating-ui/index.ts +5 -1
- package/src/components/tooltip/index.ts +3 -1
- package/src/styles/_floating-ui.scss +377 -280
package/indexv2.html
CHANGED
|
@@ -192,6 +192,16 @@
|
|
|
192
192
|
<item value="8">Item 8</item>
|
|
193
193
|
<item value="9">Item 9</item>
|
|
194
194
|
<item value="10">Item 10</item>
|
|
195
|
+
<item value="11">Item 11</item>
|
|
196
|
+
<item value="12">Item 12</item>
|
|
197
|
+
<item value="13">Item 13</item>
|
|
198
|
+
<item value="14">Item 14</item>
|
|
199
|
+
<item value="15">Item 15</item>
|
|
200
|
+
<item value="16">Item 16</item>
|
|
201
|
+
<item value="17">Item 17</item>
|
|
202
|
+
<item value="18">Item 18</item>
|
|
203
|
+
<item value="19">Item 19</item>
|
|
204
|
+
<item value="20">Item 20</item>
|
|
195
205
|
</bs-dropdown>
|
|
196
206
|
|
|
197
207
|
<h5>Form (Rows)</h5>
|
|
@@ -218,6 +228,21 @@
|
|
|
218
228
|
<item value="3">Item 3</item>
|
|
219
229
|
<item value="4">Item 4</item>
|
|
220
230
|
<item value="5">Item 5</item>
|
|
231
|
+
<item value="6">Item 6</item>
|
|
232
|
+
<item value="7">Item 7</item>
|
|
233
|
+
<item value="8">Item 8</item>
|
|
234
|
+
<item value="9">Item 9</item>
|
|
235
|
+
<item value="10">Item 10</item>
|
|
236
|
+
<item value="11">Item 11</item>
|
|
237
|
+
<item value="12">Item 12</item>
|
|
238
|
+
<item value="13">Item 13</item>
|
|
239
|
+
<item value="14">Item 14</item>
|
|
240
|
+
<item value="15">Item 15</item>
|
|
241
|
+
<item value="16">Item 16</item>
|
|
242
|
+
<item value="17">Item 17</item>
|
|
243
|
+
<item value="18">Item 18</item>
|
|
244
|
+
<item value="19">Item 19</item>
|
|
245
|
+
<item value="20">Item 20</item>
|
|
221
246
|
</bs-form-control>
|
|
222
247
|
</row>
|
|
223
248
|
<div>
|
|
@@ -447,6 +472,36 @@
|
|
|
447
472
|
<appended-button>Run</appended-button>
|
|
448
473
|
</bs-input-group>
|
|
449
474
|
|
|
475
|
+
<h5>Tooltip</h5>
|
|
476
|
+
|
|
477
|
+
<div class="bs">
|
|
478
|
+
<div class="d-flex justify-content-between">
|
|
479
|
+
<bs-tooltip placement="GD.Components.TooltipPlacements.Right" type="GD.Components.TooltipTypes.Dark"
|
|
480
|
+
options='{ "trigger": "click" }'>
|
|
481
|
+
<btn-props type="GD.Components.ButtonTypes.OutlineDanger">Test Tooltip</btn-props>
|
|
482
|
+
This is a tooltip.
|
|
483
|
+
</bs-tooltip>
|
|
484
|
+
|
|
485
|
+
<bs-tooltip placement="GD.Components.TooltipPlacements.Top" type="GD.Components.TooltipTypes.LightBorder"
|
|
486
|
+
options='{ "trigger": "click" }'>
|
|
487
|
+
<btn-props type="GD.Components.ButtonTypes.OutlineDanger">Test Tooltip</btn-props>
|
|
488
|
+
This is a tooltip.
|
|
489
|
+
</bs-tooltip>
|
|
490
|
+
|
|
491
|
+
<bs-tooltip placement="GD.Components.TooltipPlacements.Left" type="GD.Components.TooltipTypes.Dark"
|
|
492
|
+
options='{ "trigger": "click" }'>
|
|
493
|
+
<btn-props type="GD.Components.ButtonTypes.OutlineDanger">Test Tooltip</btn-props>
|
|
494
|
+
This is a tooltip.
|
|
495
|
+
</bs-tooltip>
|
|
496
|
+
|
|
497
|
+
<bs-tooltip placement="GD.Components.TooltipPlacements.Bottom" type="GD.Components.TooltipTypes.Dark"
|
|
498
|
+
options='{ "trigger": "click" }'>
|
|
499
|
+
<btn-props type="GD.Components.ButtonTypes.OutlineDanger">Test Tooltip</btn-props>
|
|
500
|
+
This is a tooltip.
|
|
501
|
+
</bs-tooltip>
|
|
502
|
+
</div>
|
|
503
|
+
</div>
|
|
504
|
+
|
|
450
505
|
<h5>Toast</h5>
|
|
451
506
|
|
|
452
507
|
<bs-toast id="toast" header-text="Header Text" muted-text="2 seconds ago" options='{ "autohide": false }'>
|
|
@@ -500,36 +555,6 @@
|
|
|
500
555
|
</toolbar-item>
|
|
501
556
|
</bs-toolbar>
|
|
502
557
|
|
|
503
|
-
<h5>Tooltip</h5>
|
|
504
|
-
|
|
505
|
-
<div class="bs">
|
|
506
|
-
<div class="d-flex justify-content-between">
|
|
507
|
-
<bs-tooltip placement="GD.Components.TooltipPlacements.TopEnd" type="GD.Components.TooltipTypes.Dark"
|
|
508
|
-
options='{ "trigger": "click" }'>
|
|
509
|
-
<btn-props type="GD.Components.ButtonTypes.OutlineDanger">Test Tooltip</btn-props>
|
|
510
|
-
This is a tooltip.
|
|
511
|
-
</bs-tooltip>
|
|
512
|
-
|
|
513
|
-
<bs-tooltip placement="GD.Components.TooltipPlacements.Top" type="GD.Components.TooltipTypes.Dark"
|
|
514
|
-
options='{ "trigger": "click" }'>
|
|
515
|
-
<btn-props type="GD.Components.ButtonTypes.OutlineDanger">Test Tooltip</btn-props>
|
|
516
|
-
This is a tooltip.
|
|
517
|
-
</bs-tooltip>
|
|
518
|
-
|
|
519
|
-
<bs-tooltip placement="GD.Components.TooltipPlacements.Bottom" type="GD.Components.TooltipTypes.Dark"
|
|
520
|
-
options='{ "trigger": "click" }'>
|
|
521
|
-
<btn-props type="GD.Components.ButtonTypes.OutlineDanger">Test Tooltip</btn-props>
|
|
522
|
-
This is a tooltip.
|
|
523
|
-
</bs-tooltip>
|
|
524
|
-
|
|
525
|
-
<bs-tooltip placement="GD.Components.TooltipPlacements.BottomStart" type="GD.Components.TooltipTypes.Dark"
|
|
526
|
-
options='{ "trigger": "click" }'>
|
|
527
|
-
<btn-props type="GD.Components.ButtonTypes.OutlineDanger">Test Tooltip</btn-props>
|
|
528
|
-
This is a tooltip.
|
|
529
|
-
</bs-tooltip>
|
|
530
|
-
</div>
|
|
531
|
-
</div>
|
|
532
|
-
|
|
533
558
|
<script type="text/javascript" showFl="false">
|
|
534
559
|
window["MyRefs"] = {};
|
|
535
560
|
window["MyLib"] = {
|
|
@@ -545,7 +570,7 @@
|
|
|
545
570
|
cardRender: (el) => { console.log("Card Render: ", el); },
|
|
546
571
|
cardBodyRender: (el) => { console.log("Card Body Render: ", el); },
|
|
547
572
|
collapseInit: obj => { window["collapseDemo"] = obj; },
|
|
548
|
-
ddlChange: (item) => {
|
|
573
|
+
ddlChange: (item) => { alert("Selected Item: " + (item ? item.text : "No Selection")); },
|
|
549
574
|
fileClicked: (btn) => { alert(btn.text + " clicked."); },
|
|
550
575
|
formCustomControl: (ctrl) => { ctrl.el.innerHTML = "<h3>Custom Control</h3>"; },
|
|
551
576
|
inputGrouponChange: (val) => { console.log("Value changed to: " + val); },
|
package/package.json
CHANGED
|
@@ -1,61 +1,61 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "gd-bs",
|
|
3
|
-
"version": "6.7.
|
|
4
|
-
"description": "Bootstrap JavaScript, TypeScript and Web Components library.",
|
|
5
|
-
"main": "build/index.js",
|
|
6
|
-
"typings": "src/index.d.ts",
|
|
7
|
-
"scripts": {
|
|
8
|
-
"all": "npm run clean && npm run generate-icons && npm run build && npm run build-icons && npm run prod && npm run prod-icons && npm run typings",
|
|
9
|
-
"build": "tsc && npm run pre-build && npm run build-bs && webpack --mode=development && npm run post-build",
|
|
10
|
-
"build-bs": "webpack --mode=production --config webpack.sass.js",
|
|
11
|
-
"build-icons": "webpack --mode=development --config webpack.icons.js",
|
|
12
|
-
"pre-build": "node ./pre-build",
|
|
13
|
-
"post-build": "node ./post-build",
|
|
14
|
-
"clean": "node ./clean.js",
|
|
15
|
-
"docs": "typedoc",
|
|
16
|
-
"generate-icons": "node ./generateIcons",
|
|
17
|
-
"package": "npm run all && npm run docs",
|
|
18
|
-
"prod": "webpack --mode=production",
|
|
19
|
-
"prod-icons": "webpack --mode=production --config webpack.icons.js",
|
|
20
|
-
"typings": "dts-bundle --configJson dts-bundle.json"
|
|
21
|
-
},
|
|
22
|
-
"repository": {
|
|
23
|
-
"type": "git",
|
|
24
|
-
"url": "git+https://github.com/gunjandatta/gd-bs.git"
|
|
25
|
-
},
|
|
26
|
-
"keywords": [
|
|
27
|
-
"Bootstrap",
|
|
28
|
-
"TypeScript"
|
|
29
|
-
],
|
|
30
|
-
"author": "Gunjan Datta <me@dattabase.com> (https://dattabase.com)",
|
|
31
|
-
"license": "MIT",
|
|
32
|
-
"bugs": {
|
|
33
|
-
"url": "https://github.com/gunjandatta/gd-bs/issues"
|
|
34
|
-
},
|
|
35
|
-
"homepage": "https://dattabase.com/extras/bs",
|
|
36
|
-
"dependencies": {
|
|
37
|
-
"@floating-ui/dom": "^1.7.1",
|
|
38
|
-
"bootstrap": "^5.3.6",
|
|
39
|
-
"bootstrap-icons": "^1.13.1",
|
|
40
|
-
"core-js": "^3.43.0"
|
|
41
|
-
},
|
|
42
|
-
"devDependencies": {
|
|
43
|
-
"@babel/core": "^7.27.4",
|
|
44
|
-
"@babel/preset-env": "^7.27.2",
|
|
45
|
-
"@types/node": "^18.19.111",
|
|
46
|
-
"autoprefixer": "^10.4.21",
|
|
47
|
-
"babel-loader": "^9.2.1",
|
|
48
|
-
"css-loader": "^6.11.0",
|
|
49
|
-
"dts-bundle": "^0.7.3",
|
|
50
|
-
"postcss-loader": "^7.3.4",
|
|
51
|
-
"sass": "^1.89.2",
|
|
52
|
-
"sass-loader": "^13.3.3",
|
|
53
|
-
"style-loader": "^3.3.4",
|
|
54
|
-
"terser-webpack-plugin": "^5.3.14",
|
|
55
|
-
"ts-loader": "^9.5.2",
|
|
56
|
-
"typedoc": "^0.24.8",
|
|
57
|
-
"typescript": "4.9.5",
|
|
58
|
-
"webpack": "^5.99.9",
|
|
59
|
-
"webpack-cli": "^5.1.4"
|
|
60
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "gd-bs",
|
|
3
|
+
"version": "6.7.9",
|
|
4
|
+
"description": "Bootstrap JavaScript, TypeScript and Web Components library.",
|
|
5
|
+
"main": "build/index.js",
|
|
6
|
+
"typings": "src/index.d.ts",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"all": "npm run clean && npm run generate-icons && npm run build && npm run build-icons && npm run prod && npm run prod-icons && npm run typings",
|
|
9
|
+
"build": "tsc && npm run pre-build && npm run build-bs && webpack --mode=development && npm run post-build",
|
|
10
|
+
"build-bs": "webpack --mode=production --config webpack.sass.js",
|
|
11
|
+
"build-icons": "webpack --mode=development --config webpack.icons.js",
|
|
12
|
+
"pre-build": "node ./pre-build",
|
|
13
|
+
"post-build": "node ./post-build",
|
|
14
|
+
"clean": "node ./clean.js",
|
|
15
|
+
"docs": "typedoc",
|
|
16
|
+
"generate-icons": "node ./generateIcons",
|
|
17
|
+
"package": "npm run all && npm run docs",
|
|
18
|
+
"prod": "webpack --mode=production",
|
|
19
|
+
"prod-icons": "webpack --mode=production --config webpack.icons.js",
|
|
20
|
+
"typings": "dts-bundle --configJson dts-bundle.json"
|
|
21
|
+
},
|
|
22
|
+
"repository": {
|
|
23
|
+
"type": "git",
|
|
24
|
+
"url": "git+https://github.com/gunjandatta/gd-bs.git"
|
|
25
|
+
},
|
|
26
|
+
"keywords": [
|
|
27
|
+
"Bootstrap",
|
|
28
|
+
"TypeScript"
|
|
29
|
+
],
|
|
30
|
+
"author": "Gunjan Datta <me@dattabase.com> (https://dattabase.com)",
|
|
31
|
+
"license": "MIT",
|
|
32
|
+
"bugs": {
|
|
33
|
+
"url": "https://github.com/gunjandatta/gd-bs/issues"
|
|
34
|
+
},
|
|
35
|
+
"homepage": "https://dattabase.com/extras/bs",
|
|
36
|
+
"dependencies": {
|
|
37
|
+
"@floating-ui/dom": "^1.7.1",
|
|
38
|
+
"bootstrap": "^5.3.6",
|
|
39
|
+
"bootstrap-icons": "^1.13.1",
|
|
40
|
+
"core-js": "^3.43.0"
|
|
41
|
+
},
|
|
42
|
+
"devDependencies": {
|
|
43
|
+
"@babel/core": "^7.27.4",
|
|
44
|
+
"@babel/preset-env": "^7.27.2",
|
|
45
|
+
"@types/node": "^18.19.111",
|
|
46
|
+
"autoprefixer": "^10.4.21",
|
|
47
|
+
"babel-loader": "^9.2.1",
|
|
48
|
+
"css-loader": "^6.11.0",
|
|
49
|
+
"dts-bundle": "^0.7.3",
|
|
50
|
+
"postcss-loader": "^7.3.4",
|
|
51
|
+
"sass": "^1.89.2",
|
|
52
|
+
"sass-loader": "^13.3.3",
|
|
53
|
+
"style-loader": "^3.3.4",
|
|
54
|
+
"terser-webpack-plugin": "^5.3.14",
|
|
55
|
+
"ts-loader": "^9.5.2",
|
|
56
|
+
"typedoc": "^0.24.8",
|
|
57
|
+
"typescript": "4.9.5",
|
|
58
|
+
"webpack": "^5.99.9",
|
|
59
|
+
"webpack-cli": "^5.1.4"
|
|
60
|
+
}
|
|
61
61
|
}
|
|
@@ -325,12 +325,16 @@ class _FloatingUI {
|
|
|
325
325
|
if (this._elArrow) {
|
|
326
326
|
let arrowX = middlewareData.arrow.x;
|
|
327
327
|
let arrowY = middlewareData.arrow.y;
|
|
328
|
+
let placement = (middlewareData.offset?.placement || this._options.placement).split('-')[0];
|
|
328
329
|
let side = {
|
|
329
330
|
top: 'bottom',
|
|
330
331
|
right: 'left',
|
|
331
332
|
bottom: 'top',
|
|
332
333
|
left: 'right'
|
|
333
|
-
}[
|
|
334
|
+
}[placement]
|
|
335
|
+
|
|
336
|
+
// Set the placement
|
|
337
|
+
this._elContent.setAttribute("data-placement", placement);
|
|
334
338
|
|
|
335
339
|
// Update the location
|
|
336
340
|
Object.assign(this._elArrow.style, {
|
|
@@ -5,7 +5,6 @@ import { IButton } from "../button/types";
|
|
|
5
5
|
import { Button, ButtonTypes } from "../button";
|
|
6
6
|
import { IDropdown } from "../dropdown/types";
|
|
7
7
|
import { Dropdown, DropdownTypes } from "../dropdown";
|
|
8
|
-
import { appendContent } from "../common";
|
|
9
8
|
import { FloatingUI, FloatingUIPlacements } from "../floating-ui";
|
|
10
9
|
|
|
11
10
|
/**
|
|
@@ -205,6 +204,9 @@ class _Tooltip extends Base<ITooltipProps> {
|
|
|
205
204
|
this._elContent = this.props.content as any;
|
|
206
205
|
}
|
|
207
206
|
|
|
207
|
+
// Set the padding
|
|
208
|
+
this._elContent.classList.add("p-2");
|
|
209
|
+
|
|
208
210
|
// Set the on create event
|
|
209
211
|
/*
|
|
210
212
|
options["onCreate"] = (tippyObj) => {
|