gd-bs 6.6.41 → 6.6.43
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/.github/workflows/build.yml +2 -2
- package/build/bs.js +1 -1
- package/build/components/navbar/index.js +26 -8
- package/build/components/navbar/templates.js +1 -1
- package/dist/gd-bs-icons.js +1 -1
- package/dist/gd-bs-icons.js.LICENSE.txt +239 -243
- package/dist/gd-bs-icons.min.js +1 -1
- package/dist/gd-bs.js +1 -1
- package/dist/gd-bs.js.LICENSE.txt +231 -235
- package/dist/gd-bs.min.js +1 -1
- package/index.html +1 -0
- package/package.json +3 -3
- package/src/components/navbar/index.ts +25 -8
- package/src/components/navbar/templates.ts +1 -0
- package/src/styles/_custom.scss +1 -0
package/index.html
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gd-bs",
|
|
3
|
-
"version": "6.6.
|
|
3
|
+
"version": "6.6.43",
|
|
4
4
|
"description": "Bootstrap JavaScript, TypeScript and Web Components library.",
|
|
5
5
|
"main": "build/index.js",
|
|
6
6
|
"typings": "src/index.d.ts",
|
|
@@ -34,9 +34,9 @@
|
|
|
34
34
|
"homepage": "https://dattabase.com/extras/bs",
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@popperjs/core": "^2.11.8",
|
|
37
|
-
"bootstrap": "^5.3.
|
|
37
|
+
"bootstrap": "^5.3.3",
|
|
38
38
|
"bootstrap-icons": "^1.11.3",
|
|
39
|
-
"core-js": "^3.
|
|
39
|
+
"core-js": "^3.38.1",
|
|
40
40
|
"tippy.js": "^6.3.7"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
@@ -40,19 +40,36 @@ class _Navbar extends Base<INavbarProps> implements INavbar {
|
|
|
40
40
|
|
|
41
41
|
// Configure the card group
|
|
42
42
|
private configure(itemTemplate: string) {
|
|
43
|
-
// See if
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
43
|
+
// See if we are applying a brand
|
|
44
|
+
if (this.props.brand) {
|
|
45
|
+
let elBrand = this.el.querySelector("span.navbar-brand") as HTMLSpanElement;
|
|
46
|
+
let elBrandLink = this.el.querySelector("a.navbar-brand") as HTMLAnchorElement;
|
|
47
|
+
|
|
48
|
+
// See if we are using a link
|
|
49
|
+
if (this.props.brandUrl || this.props.onClickBrand) {
|
|
50
|
+
// Remove the element
|
|
51
|
+
elBrand ? elBrand.parentElement.removeChild(elBrand) : null;
|
|
52
|
+
|
|
47
53
|
// Update the brand
|
|
48
|
-
|
|
54
|
+
elBrandLink ? elBrandLink.href = this.props.brandUrl : null;
|
|
49
55
|
|
|
50
56
|
// Append the content
|
|
51
|
-
appendContent(
|
|
57
|
+
appendContent(elBrandLink, this.props.brand);
|
|
52
58
|
} else {
|
|
53
|
-
// Remove the
|
|
54
|
-
|
|
59
|
+
// Remove the link element
|
|
60
|
+
elBrandLink ? elBrandLink.parentElement.removeChild(elBrandLink) : null;
|
|
61
|
+
|
|
62
|
+
// Append the content
|
|
63
|
+
appendContent(elBrand, this.props.brand);
|
|
55
64
|
}
|
|
65
|
+
} else {
|
|
66
|
+
// Remove the brand link
|
|
67
|
+
let elBrandLink = this.el.querySelector("a.navbar-brand");
|
|
68
|
+
if (elBrandLink) { elBrandLink.parentNode.removeChild(elBrandLink); }
|
|
69
|
+
|
|
70
|
+
// Remove the brand element
|
|
71
|
+
let elBrand = this.el.querySelector("span.navbar-brand");
|
|
72
|
+
if (elBrand) { elBrand.parentNode.removeChild(elBrand); }
|
|
56
73
|
}
|
|
57
74
|
|
|
58
75
|
// Update the nav bar
|
|
@@ -3,6 +3,7 @@ export const HTML = `
|
|
|
3
3
|
<nav class="navbar navbar-expand-lg">
|
|
4
4
|
<div class="container-fluid">
|
|
5
5
|
<a class="navbar-brand" href="#"></a>
|
|
6
|
+
<span class="navbar-brand mb-0 h1"></span>
|
|
6
7
|
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" aria-expanded="false"
|
|
7
8
|
aria-label="Toggle Navigation">
|
|
8
9
|
<span class="navbar-toggler-icon"></span>
|