@kakadu/components 6.3.6 → 6.3.7
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.
|
@@ -5,5 +5,6 @@ export type CardProperties = HTMLProps<HTMLButtonElement> & {
|
|
|
5
5
|
readonly title: string;
|
|
6
6
|
readonly description: string;
|
|
7
7
|
readonly action: string;
|
|
8
|
+
readonly innerClassName?: string;
|
|
8
9
|
};
|
|
9
|
-
export default function Card({ ref, icon, title, description, action, href, target, rel, className, ...properties }: CardProperties): React.JSX.Element;
|
|
10
|
+
export default function Card({ ref, icon, title, description, action, href, target, rel, className, innerClassName, ...properties }: CardProperties): React.JSX.Element;
|
package/build/components/card.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../jsx-runtime-BB_1_6y_.js"),a=require("@kuma-ui/core"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("../jsx-runtime-BB_1_6y_.js"),a=require("@kuma-ui/core"),k=require("../theme.js"),c=require("../icons/icon.js"),s=require("./flex.js"),n=require("./text.js"),R=require("./click-ripples.js"),i=require("./hover-gradient.js"),q=require("./button.js"),E=require("./atom.js");function S({ref:u,icon:o,title:l,description:d,action:m,href:r,target:x,rel:p,className:j,innerClassName:h,...f}){const t=r!==void 0;return e.jsxRuntimeExports.jsxs(E.default,{...f,reference:u,as:t?"a":"button",type:t?void 0:"button",href:t?r:void 0,target:t?x:void 0,rel:t?p:void 0,className:a.cx(k.effectStyles,q.buttonSecondaryStyles,"kakadu-components-1387630570",j),children:[e.jsxRuntimeExports.jsxs(s.default,{gap:.5,direction:"column",className:h,children:[e.jsxRuntimeExports.jsx(n.Span,{className:"kakadu-components-1301774894",children:e.jsxRuntimeExports.jsxs(s.default,{gap:.5,direction:"row",preset:"start",children:[o?e.jsxRuntimeExports.jsx(c.default,{width:16,height:16,type:o,className:a.cx(c.iconShadowStyles,"kakadu-components-782417605")}):null,l]})}),e.jsxRuntimeExports.jsx(n.Paragraph,{className:"kakadu-components-3061837309",children:d}),e.jsxRuntimeExports.jsx(s.default,{preset:"end",children:e.jsxRuntimeExports.jsx(n.Span,{className:"kakadu-components-777975485",children:m})})]}),e.jsxRuntimeExports.jsx(R.default,{size:250,className:"kakadu-components-2967167444"}),e.jsxRuntimeExports.jsx(i.default,{size:300,className:i.normalBlendStyles})]})}exports.default=S;
|
|
@@ -1,39 +1,40 @@
|
|
|
1
|
-
import { j as
|
|
1
|
+
import { j as e } from "../jsx-runtime-B4hRZ52C.mjs";
|
|
2
2
|
import { cx as a } from "@kuma-ui/core";
|
|
3
|
-
import { effectStyles as
|
|
4
|
-
import
|
|
3
|
+
import { effectStyles as h } from "../theme.mjs";
|
|
4
|
+
import k, { iconShadowStyles as j } from "../icons/icon.mjs";
|
|
5
5
|
import s from "./flex.mjs";
|
|
6
|
-
import { Span as n, Paragraph as
|
|
6
|
+
import { Span as n, Paragraph as N } from "./text.mjs";
|
|
7
7
|
import y from "./click-ripples.mjs";
|
|
8
|
-
import
|
|
9
|
-
import { buttonSecondaryStyles as
|
|
10
|
-
import
|
|
11
|
-
function
|
|
8
|
+
import S, { normalBlendStyles as v } from "./hover-gradient.mjs";
|
|
9
|
+
import { buttonSecondaryStyles as g } from "./button.mjs";
|
|
10
|
+
import b from "./atom.mjs";
|
|
11
|
+
function I({
|
|
12
12
|
ref: m,
|
|
13
13
|
icon: r,
|
|
14
14
|
title: i,
|
|
15
15
|
description: c,
|
|
16
|
-
action:
|
|
16
|
+
action: l,
|
|
17
17
|
href: t,
|
|
18
|
-
target:
|
|
18
|
+
target: d,
|
|
19
19
|
rel: p,
|
|
20
20
|
className: f,
|
|
21
|
-
|
|
21
|
+
innerClassName: u,
|
|
22
|
+
...x
|
|
22
23
|
}) {
|
|
23
|
-
const
|
|
24
|
-
return /* @__PURE__ */
|
|
25
|
-
/* @__PURE__ */
|
|
26
|
-
/* @__PURE__ */
|
|
27
|
-
r ? /* @__PURE__ */
|
|
24
|
+
const o = t !== void 0;
|
|
25
|
+
return /* @__PURE__ */ e.jsxs(b, { ...x, reference: m, as: o ? "a" : "button", type: o ? void 0 : "button", href: o ? t : void 0, target: o ? d : void 0, rel: o ? p : void 0, className: a(h, g, "kakadu-components-1387630570", f), children: [
|
|
26
|
+
/* @__PURE__ */ e.jsxs(s, { gap: 0.5, direction: "column", className: u, children: [
|
|
27
|
+
/* @__PURE__ */ e.jsx(n, { className: "kakadu-components-1301774894", children: /* @__PURE__ */ e.jsxs(s, { gap: 0.5, direction: "row", preset: "start", children: [
|
|
28
|
+
r ? /* @__PURE__ */ e.jsx(k, { width: 16, height: 16, type: r, className: a(j, "kakadu-components-782417605") }) : null,
|
|
28
29
|
i
|
|
29
30
|
] }) }),
|
|
30
|
-
/* @__PURE__ */
|
|
31
|
-
/* @__PURE__ */
|
|
31
|
+
/* @__PURE__ */ e.jsx(N, { className: "kakadu-components-3061837309", children: c }),
|
|
32
|
+
/* @__PURE__ */ e.jsx(s, { preset: "end", children: /* @__PURE__ */ e.jsx(n, { className: "kakadu-components-777975485", children: l }) })
|
|
32
33
|
] }),
|
|
33
|
-
/* @__PURE__ */
|
|
34
|
-
/* @__PURE__ */
|
|
34
|
+
/* @__PURE__ */ e.jsx(y, { size: 250, className: "kakadu-components-2967167444" }),
|
|
35
|
+
/* @__PURE__ */ e.jsx(S, { size: 300, className: v })
|
|
35
36
|
] });
|
|
36
37
|
}
|
|
37
38
|
export {
|
|
38
|
-
|
|
39
|
+
I as default
|
|
39
40
|
};
|
|
@@ -4,7 +4,7 @@ export declare const footerSections: readonly ["services", "results", "about", "
|
|
|
4
4
|
export declare const footerSectionLinks: {
|
|
5
5
|
readonly services: readonly ["kakaduPlay", "kakaduGuide", "kakaduAcademy"];
|
|
6
6
|
readonly results: readonly ["press", "articles"];
|
|
7
|
-
readonly about: readonly ["contact"];
|
|
7
|
+
readonly about: readonly ["contact", "home"];
|
|
8
8
|
readonly compliance: readonly ["privacyPolicy", "ethicalGuidelines", "status"];
|
|
9
9
|
};
|
|
10
10
|
export type FooterSection = (typeof footerSections)[number];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const s=require("../jsx-runtime-BB_1_6y_.js"),b=require("react"),y=require("@kuma-ui/core"),R=require("../theme.js"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const s=require("../jsx-runtime-BB_1_6y_.js"),b=require("react"),y=require("@kuma-ui/core"),R=require("../theme.js"),u=require("./flex.js"),k=require("./text.js"),w=require("./logos/kakadu-logo.js"),N=require("./aria-text.js"),q=require("./wrapper.js"),P="kakadu-components-975968984",x=["services","results","about","compliance"],E={services:["kakaduPlay","kakaduGuide","kakaduAcademy"],results:["press","articles"],about:["contact","home"],compliance:["privacyPolicy","ethicalGuidelines","status"]},_={services:{text:"Services",links:{kakaduPlay:{text:"Kakadu Play",href:"https://kakadu.no/veiledninger"},kakaduGuide:{text:"Kakadu Guide",href:"https://guide.kakadu.no"},kakaduAcademy:{text:"Kakadu Academy",href:"https://academy.kakadu.no"}}},results:{text:"Results",links:{press:{text:"Press",href:"https://kakadu.no/press"},articles:{text:"Articles",href:"https://kakadu.no/articles"}}},about:{text:"About",links:{contact:{text:"Contact us",href:"https://kakadu.no/contact"},home:{text:"Home",href:"https://kakadu.no"}}},compliance:{text:"Compliance",links:{privacyPolicy:{text:"Privacy policy",href:"https://kakadu.no/legal/privacy-policy"},ethicalGuidelines:{text:"Ethical guidelines",href:"https://kakadu.no/legal/ethical-guidelines"},status:{text:"Status",href:"https://kakadu.instatus.com",rel:"noopener noreferrer",target:"_blank"}}}};function d(t,r,i){if(i!==!1&&(i==null?void 0:i.index)!==void 0)return i.index;const e=r.indexOf(t);return e===-1?r.length+1:e+1}function S(t,r={},i=[]){var p,m,h,f;const e=new Set([...Object.keys(r),...Object.keys(t)]),a=[];for(const c of e){const o=t[c];if(o===!1)continue;const j=(o==null?void 0:o.text)??((p=r[c])==null?void 0:p.text),g=(o==null?void 0:o.href)??((m=r[c])==null?void 0:m.href);j===void 0||g===void 0||a.push({key:c,text:j,href:g,rel:(o==null?void 0:o.rel)??((h=r[c])==null?void 0:h.rel),target:(o==null?void 0:o.target)??((f=r[c])==null?void 0:f.target)})}const n=new Set(a.map(c=>c.key)),l=i.filter(c=>n.has(c));return a.toSorted((c,o)=>d(c.key,l,t[c.key])-d(o.key,l,t[o.key]))}function A(t){const r=x.filter(e=>(t==null?void 0:t[e])!==!1),i=[];for(const e of x){if((t==null?void 0:t[e])===!1)continue;const a=_[e],n=t==null?void 0:t[e];i.push({key:e,title:(n==null?void 0:n.text)??a.text,links:S((n==null?void 0:n.links)??{},a.links,E[e]),index:d(e,r,n)})}for(const[e,a]of Object.entries(t??{})){if(x.includes(e)||a===!1)continue;const n=S(a.links??{});n.length===0&&a.text===void 0||i.push({key:e,title:a.text??e,links:n,index:d(e,r,a)})}return i.toSorted((e,a)=>e.index-a.index)}function L({width:t="page",sections:r,attribution:i,className:e}){const a=b.useMemo(()=>A(r),[r]);return s.jsxRuntimeExports.jsxs(q.default,{as:"footer",gap:2,width:t,className:y.cx("kakadu-components-3130980543",e),children:[s.jsxRuntimeExports.jsxs(u.default,{wrap:!0,"data-theme":"dark",direction:"row",gap:4,className:y.cx(R.default,"kakadu-components-82784222"),children:[a.map(n=>n.links.length>0?s.jsxRuntimeExports.jsxs(u.default,{direction:"column",preset:"start",gap:.5,children:[s.jsxRuntimeExports.jsx(k.Paragraph,{children:s.jsxRuntimeExports.jsx("strong",{children:n.title})}),s.jsxRuntimeExports.jsx(k.Paragraph,{as:"ul",className:P,children:n.links.map(l=>s.jsxRuntimeExports.jsx("li",{children:s.jsxRuntimeExports.jsx("a",{href:l.href,rel:l.rel,target:l.target,children:l.text})},l.key))})]},n.key):null),s.jsxRuntimeExports.jsx(u.default,{fill:!0,className:"kakadu-components-3520395370",children:s.jsxRuntimeExports.jsx("a",{href:"https://businessnorway.com/companies/kakadu-ignite-as",target:"_blank",rel:"noopener noreferrer",className:"kakadu-components-3521477705",children:s.jsxRuntimeExports.jsx("img",{alt:"Made in Norway",src:"https://components.kakadu.no/images/made-in-norway.png",width:"76",height:"93",className:"kakadu-components-2329568054"})})})]}),s.jsxRuntimeExports.jsxs(u.default,{wrap:!0,"data-theme":"dark",direction:"row-reverse",gap:2,alignment:"flex-end",distribution:"space-between",className:R.default,children:[i?s.jsxRuntimeExports.jsx(k.Span,{className:"kakadu-components-1667529929",children:i}):null,s.jsxRuntimeExports.jsxs(u.default,{fill:!0,direction:"row",gap:1,alignment:"center",children:[s.jsxRuntimeExports.jsxs("a",{href:"https://kakadu.no",children:[s.jsxRuntimeExports.jsx(N.default,{children:"Kakadu"}),s.jsxRuntimeExports.jsx(w.default,{width:90,className:"kakadu-components-3103582715"})]}),s.jsxRuntimeExports.jsxs(k.Span,{className:"kakadu-components-250962410",children:["© ",new Date().getFullYear()," Kakadu Ignite AS"]})]})]})]})}exports.default=L;exports.footerSectionLinks=E;exports.footerSections=x;
|
|
@@ -10,7 +10,7 @@ import K from "./wrapper.mjs";
|
|
|
10
10
|
const G = "kakadu-components-975968984", d = ["services", "results", "about", "compliance"], L = {
|
|
11
11
|
services: ["kakaduPlay", "kakaduGuide", "kakaduAcademy"],
|
|
12
12
|
results: ["press", "articles"],
|
|
13
|
-
about: ["contact"],
|
|
13
|
+
about: ["contact", "home"],
|
|
14
14
|
compliance: ["privacyPolicy", "ethicalGuidelines", "status"]
|
|
15
15
|
}, O = {
|
|
16
16
|
services: {
|
|
@@ -48,7 +48,11 @@ const G = "kakadu-components-975968984", d = ["services", "results", "about", "c
|
|
|
48
48
|
links: {
|
|
49
49
|
contact: {
|
|
50
50
|
text: "Contact us",
|
|
51
|
-
href: "https://
|
|
51
|
+
href: "https://kakadu.no/contact"
|
|
52
|
+
},
|
|
53
|
+
home: {
|
|
54
|
+
text: "Home",
|
|
55
|
+
href: "https://kakadu.no"
|
|
52
56
|
}
|
|
53
57
|
}
|
|
54
58
|
},
|
|
@@ -57,11 +61,11 @@ const G = "kakadu-components-975968984", d = ["services", "results", "about", "c
|
|
|
57
61
|
links: {
|
|
58
62
|
privacyPolicy: {
|
|
59
63
|
text: "Privacy policy",
|
|
60
|
-
href: "https://
|
|
64
|
+
href: "https://kakadu.no/legal/privacy-policy"
|
|
61
65
|
},
|
|
62
66
|
ethicalGuidelines: {
|
|
63
67
|
text: "Ethical guidelines",
|
|
64
|
-
href: "https://
|
|
68
|
+
href: "https://kakadu.no/legal/ethical-guidelines"
|
|
65
69
|
},
|
|
66
70
|
status: {
|
|
67
71
|
text: "Status",
|
|
@@ -72,65 +76,65 @@ const G = "kakadu-components-975968984", d = ["services", "results", "about", "c
|
|
|
72
76
|
}
|
|
73
77
|
}
|
|
74
78
|
};
|
|
75
|
-
function u(
|
|
79
|
+
function u(t, r, i) {
|
|
76
80
|
if (i !== !1 && (i == null ? void 0 : i.index) !== void 0)
|
|
77
81
|
return i.index;
|
|
78
|
-
const
|
|
79
|
-
return
|
|
82
|
+
const e = r.indexOf(t);
|
|
83
|
+
return e === -1 ? r.length + 1 : e + 1;
|
|
80
84
|
}
|
|
81
|
-
function b(
|
|
82
|
-
var p, m, f
|
|
83
|
-
const
|
|
84
|
-
for (const l of
|
|
85
|
-
const
|
|
86
|
-
if (
|
|
85
|
+
function b(t, r = {}, i = []) {
|
|
86
|
+
var p, h, m, f;
|
|
87
|
+
const e = /* @__PURE__ */ new Set([...Object.keys(r), ...Object.keys(t)]), s = [];
|
|
88
|
+
for (const l of e) {
|
|
89
|
+
const o = t[l];
|
|
90
|
+
if (o === !1)
|
|
87
91
|
continue;
|
|
88
|
-
const x = (
|
|
92
|
+
const x = (o == null ? void 0 : o.text) ?? ((p = r[l]) == null ? void 0 : p.text), g = (o == null ? void 0 : o.href) ?? ((h = r[l]) == null ? void 0 : h.href);
|
|
89
93
|
x === void 0 || g === void 0 || s.push({
|
|
90
94
|
key: l,
|
|
91
95
|
text: x,
|
|
92
96
|
href: g,
|
|
93
|
-
rel: (
|
|
94
|
-
target: (
|
|
97
|
+
rel: (o == null ? void 0 : o.rel) ?? ((m = r[l]) == null ? void 0 : m.rel),
|
|
98
|
+
target: (o == null ? void 0 : o.target) ?? ((f = r[l]) == null ? void 0 : f.target)
|
|
95
99
|
});
|
|
96
100
|
}
|
|
97
101
|
const n = new Set(s.map((l) => l.key)), c = i.filter((l) => n.has(l));
|
|
98
|
-
return s.toSorted((l,
|
|
102
|
+
return s.toSorted((l, o) => u(l.key, c, t[l.key]) - u(o.key, c, t[o.key]));
|
|
99
103
|
}
|
|
100
|
-
function F(
|
|
101
|
-
const
|
|
102
|
-
for (const
|
|
103
|
-
if ((
|
|
104
|
+
function F(t) {
|
|
105
|
+
const r = d.filter((e) => (t == null ? void 0 : t[e]) !== !1), i = [];
|
|
106
|
+
for (const e of d) {
|
|
107
|
+
if ((t == null ? void 0 : t[e]) === !1)
|
|
104
108
|
continue;
|
|
105
|
-
const s = O[
|
|
109
|
+
const s = O[e], n = t == null ? void 0 : t[e];
|
|
106
110
|
i.push({
|
|
107
|
-
key:
|
|
111
|
+
key: e,
|
|
108
112
|
title: (n == null ? void 0 : n.text) ?? s.text,
|
|
109
|
-
links: b((n == null ? void 0 : n.links) ?? {}, s.links, L[
|
|
110
|
-
index: u(
|
|
113
|
+
links: b((n == null ? void 0 : n.links) ?? {}, s.links, L[e]),
|
|
114
|
+
index: u(e, r, n)
|
|
111
115
|
});
|
|
112
116
|
}
|
|
113
|
-
for (const [
|
|
114
|
-
if (d.includes(
|
|
117
|
+
for (const [e, s] of Object.entries(t ?? {})) {
|
|
118
|
+
if (d.includes(e) || s === !1)
|
|
115
119
|
continue;
|
|
116
120
|
const n = b(s.links ?? {});
|
|
117
121
|
n.length === 0 && s.text === void 0 || i.push({
|
|
118
|
-
key:
|
|
119
|
-
title: s.text ??
|
|
122
|
+
key: e,
|
|
123
|
+
title: s.text ?? e,
|
|
120
124
|
links: n,
|
|
121
|
-
index: u(
|
|
125
|
+
index: u(e, r, s)
|
|
122
126
|
});
|
|
123
127
|
}
|
|
124
|
-
return i.toSorted((
|
|
128
|
+
return i.toSorted((e, s) => e.index - s.index);
|
|
125
129
|
}
|
|
126
|
-
function
|
|
127
|
-
width:
|
|
128
|
-
sections:
|
|
130
|
+
function W({
|
|
131
|
+
width: t = "page",
|
|
132
|
+
sections: r,
|
|
129
133
|
attribution: i,
|
|
130
|
-
className:
|
|
134
|
+
className: e
|
|
131
135
|
}) {
|
|
132
|
-
const s = N(() => F(
|
|
133
|
-
return /* @__PURE__ */ a.jsxs(K, { as: "footer", gap: 2, width:
|
|
136
|
+
const s = N(() => F(r), [r]);
|
|
137
|
+
return /* @__PURE__ */ a.jsxs(K, { as: "footer", gap: 2, width: t, className: y("kakadu-components-3130980543", e), children: [
|
|
134
138
|
/* @__PURE__ */ a.jsxs(k, { wrap: !0, "data-theme": "dark", direction: "row", gap: 4, className: y(j, "kakadu-components-82784222"), children: [
|
|
135
139
|
s.map((n) => n.links.length > 0 ? /* @__PURE__ */ a.jsxs(k, { direction: "column", preset: "start", gap: 0.5, children: [
|
|
136
140
|
/* @__PURE__ */ a.jsx(S, { children: /* @__PURE__ */ a.jsx("strong", { children: n.title }) }),
|
|
@@ -155,7 +159,7 @@ function Y({
|
|
|
155
159
|
] });
|
|
156
160
|
}
|
|
157
161
|
export {
|
|
158
|
-
|
|
162
|
+
W as default,
|
|
159
163
|
L as footerSectionLinks,
|
|
160
164
|
d as footerSections
|
|
161
165
|
};
|