@openeuropa/bcl-data-navigation 0.1.3 → 0.1.202408021145

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.
@@ -0,0 +1,31 @@
1
+ const drupalAttribute = require("drupal-attribute");
2
+
3
+ module.exports = {
4
+ nav: true,
5
+ tabs: true,
6
+ attributes: new drupalAttribute().addClass("bcl__nav"),
7
+ items: [
8
+ {
9
+ label: "I'm a link 1",
10
+ path: "/example.html",
11
+ },
12
+ {
13
+ label: "I'm a link 2",
14
+ path: "/example.html",
15
+ },
16
+ {
17
+ label: "I'm a link 3",
18
+ path: "/example.html",
19
+ },
20
+ {
21
+ label: "I'm a link active",
22
+ path: "/example.html",
23
+ active: true,
24
+ },
25
+ {
26
+ label: "I'm a link disabled",
27
+ path: "/example.html",
28
+ disabled: true,
29
+ },
30
+ ],
31
+ };
@@ -0,0 +1,81 @@
1
+ const drupalAttribute = require("drupal-attribute");
2
+
3
+ module.exports = {
4
+ vertical: true,
5
+ attributes: new drupalAttribute().addClass("bcl__nav"),
6
+ items: [
7
+ {
8
+ label: "I'm a link 1",
9
+ path: "/example.html",
10
+ navigation: {
11
+ items: [
12
+ {
13
+ label: "I'm a child link",
14
+ path: "/example.html",
15
+ },
16
+ ],
17
+ },
18
+ },
19
+ {
20
+ label: "I'm a link 2",
21
+ path: "/example.html",
22
+ navigation: {
23
+ items: [
24
+ {
25
+ label: "I'm a child",
26
+ path: "/example.html",
27
+ },
28
+ {
29
+ label: "I'm a child",
30
+ path: "/example.html",
31
+ },
32
+ ],
33
+ },
34
+ },
35
+ {
36
+ label: "I'm a link 3",
37
+ path: "/example.html",
38
+ navigation: {
39
+ vertical: true,
40
+ attributes: new drupalAttribute().addClass("ps-3"),
41
+ items: [
42
+ {
43
+ label: "I'm a child link",
44
+ path: "/example.html",
45
+ navigation: {
46
+ vertical: true,
47
+ attributes: new drupalAttribute().addClass("ps-3"),
48
+ items: [
49
+ {
50
+ label: "I'm a child link",
51
+ path: "/example.html",
52
+ },
53
+ {
54
+ label: "I'm a child link",
55
+ path: "/example.html",
56
+ },
57
+ {
58
+ label: "I'm a child link",
59
+ path: "/example.html",
60
+ },
61
+ ],
62
+ },
63
+ },
64
+ {
65
+ label: "I'm a child link",
66
+ path: "/example.html",
67
+ },
68
+ {
69
+ label: "I'm a child link",
70
+ path: "/example.html",
71
+ },
72
+ ],
73
+ },
74
+ },
75
+ {
76
+ label: "I'm a link disabled",
77
+ path: "/example.html",
78
+ disabled: true,
79
+ },
80
+ ],
81
+ };
@@ -1,14 +1,15 @@
1
1
  const drupalAttribute = require("drupal-attribute");
2
+ const { getDummyText } = require("@openeuropa/bcl-data-utils");
2
3
 
3
4
  module.exports = {
4
5
  tabs: true,
6
+ nav: true,
5
7
  tabs_content: true,
6
8
  items: [
7
9
  {
8
10
  label: "I'm a link",
9
11
  path: "#first",
10
- content:
11
- "This is a demo content for the First Tab. Lorem ipsum dolor sit amet, consectetur adipiscing elit.",
12
+ content: `<p class="mt-4">This is a demo content for the First Tab. ${getDummyText()}</p>`,
12
13
  id: "first-tab",
13
14
  target: "first",
14
15
  attributes: new drupalAttribute()
@@ -19,8 +20,7 @@ module.exports = {
19
20
  {
20
21
  label: "I'm a button",
21
22
  button: true,
22
- content:
23
- "This is a demo content for the Second Tab. Lorem ipsum dolor sit amet, consectetur adipiscing elit.",
23
+ content: `<p class="mt-4">This is a demo content for the Second Tab. ${getDummyText()}</p>`,
24
24
  id: "second-tab",
25
25
  target: "second",
26
26
  attributes: new drupalAttribute()
@@ -33,8 +33,7 @@ module.exports = {
33
33
  label: "I'm a disabled button",
34
34
  button: true,
35
35
  disabled: true,
36
- content:
37
- "This is a demo content for the Third Tab. Lorem ipsum dolor sit amet, consectetur adipiscing elit.",
36
+ content: `<p class="mt-4">This is a demo content for the Third Tab.</p>${getDummyText()}</p>`,
38
37
  id: "third-tab",
39
38
  target: "third",
40
39
  attributes: new drupalAttribute()
@@ -43,45 +42,11 @@ module.exports = {
43
42
  .setAttribute("data-bs-target", "#third")
44
43
  .setAttribute("aria-controls", "third"),
45
44
  },
46
- {
47
- id: "dropdown-1",
48
- link: true,
49
- dropdown: true,
50
- trigger: {
51
- label: "Dropdown Toggle",
52
- path: "#",
53
- attributes: new drupalAttribute().addClass("nav-link"),
54
- },
55
- items: [
56
- {
57
- label: "I'm a link",
58
- path: "/example.html",
59
- },
60
- {
61
- label: "I'm a button",
62
- button: true,
63
- },
64
- {
65
- divider: true,
66
- },
67
- {
68
- label: "I'm a disabled button",
69
- button: true,
70
- disabled: true,
71
- },
72
- {
73
- label: "I'm a active button",
74
- button: true,
75
- active: true,
76
- },
77
- ],
78
- },
79
45
  {
80
46
  label: "I'm a active button",
81
47
  button: true,
82
48
  active: true,
83
- content:
84
- "This is a demo content for the Fourth Tab. Lorem ipsum dolor sit amet, consectetur adipiscing elit.",
49
+ content: `<p class="mt-4">This is a demo content for the Fourth Tab. ${getDummyText()}</p>`,
85
50
  id: "fourth-tab",
86
51
  target: "fourth",
87
52
  attributes: new drupalAttribute()
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@openeuropa/bcl-data-navigation",
3
3
  "author": "European Commission",
4
4
  "license": "EUPL-1.2",
5
- "version": "0.1.3",
5
+ "version": "0.1.202408021145",
6
6
  "description": "OE - BCL data navigation",
7
7
  "publishConfig": {
8
8
  "access": "public"
@@ -21,5 +21,5 @@
21
21
  "design-system",
22
22
  "twig"
23
23
  ],
24
- "gitHead": "ab1587b9ba4971ea0ca72c3de6b632f2c314c200"
24
+ "gitHead": "7ee2013f7f64a70ddfa35228a9a65967dd71eec3"
25
25
  }