@oslokommune/punkt-react 5.1.19 → 5.2.0
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/CHANGELOG.md +248 -123
- package/dist/index.d.ts +1 -0
- package/dist/punkt-react.es.js +703 -557
- package/dist/punkt-react.umd.js +11 -11
- package/dist/textinput/Textinput.d.ts +26 -0
- package/package.json +3 -3
- package/src/components/footer/Footer.test.tsx +35 -35
- package/src/components/footer/__snapshots__/Footer.test.tsx.snap +9 -71
- package/src/components/footerSimple/FooterSimple.test.tsx +1 -1
- package/src/components/footerSimple/__snapshots__/FooterSimple.test.tsx.snap +4 -41
- package/src/components/index.ts +3 -3
- package/src/components/linkcard/LinkCard.test.tsx +1 -1
- package/src/components/linkcard/__snapshots__/LinkCard.test.tsx.snap +4 -11
- package/src/components/tag/Tag.test.tsx +4 -4
- package/src/components/tag/__snapshots__/Tag.test.tsx.snap +2 -2
- package/src/components/textinput/Textinput.test.tsx +60 -0
- package/src/components/textinput/Textinput.tsx +217 -0
package/dist/punkt-react.umd.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(g,E){typeof exports=="object"&&typeof module<"u"?E(exports,require("react")):typeof define=="function"&&define.amd?define(["exports","react"],E):(g=typeof globalThis<"u"?globalThis:g||self,E(g["punkt-react"]={},g.React))})(this,function(g,E){"use strict";function
|
|
1
|
+
(function(g,E){typeof exports=="object"&&typeof module<"u"?E(exports,require("react")):typeof define=="function"&&define.amd?define(["exports","react"],E):(g=typeof globalThis<"u"?globalThis:g||self,E(g["punkt-react"]={},g.React))})(this,function(g,E){"use strict";function Xe(l){return l&&l.__esModule&&Object.prototype.hasOwnProperty.call(l,"default")?l.default:l}var le={exports:{}},U={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.min.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
9
|
+
*/var Ee;function Ze(){if(Ee)return U;Ee=1;var l=E,s=Symbol.for("react.element"),o=Symbol.for("react.fragment"),c=Object.prototype.hasOwnProperty,f=l.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function p(h,d,N){var y,P={},T=null,S=null;N!==void 0&&(T=""+N),d.key!==void 0&&(T=""+d.key),d.ref!==void 0&&(S=d.ref);for(y in d)c.call(d,y)&&!a.hasOwnProperty(y)&&(P[y]=d[y]);if(h&&h.defaultProps)for(y in d=h.defaultProps,d)P[y]===void 0&&(P[y]=d[y]);return{$$typeof:s,type:h,key:T,ref:S,props:P,_owner:f.current}}return U.Fragment=o,U.jsx=p,U.jsxs=p,U}var H={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,18 +14,18 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
18
|
-
`+
|
|
19
|
-
`),
|
|
20
|
-
`),
|
|
21
|
-
`+
|
|
17
|
+
*/var Re;function Qe(){return Re||(Re=1,process.env.NODE_ENV!=="production"&&function(){var l=E,s=Symbol.for("react.element"),o=Symbol.for("react.portal"),c=Symbol.for("react.fragment"),f=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),p=Symbol.for("react.provider"),h=Symbol.for("react.context"),d=Symbol.for("react.forward_ref"),N=Symbol.for("react.suspense"),y=Symbol.for("react.suspense_list"),P=Symbol.for("react.memo"),T=Symbol.for("react.lazy"),S=Symbol.for("react.offscreen"),D=Symbol.iterator,F="@@iterator";function A(e){if(e===null||typeof e!="object")return null;var t=D&&e[D]||e[F];return typeof t=="function"?t:null}var C=l.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function R(e){{for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];ue("error",e,n)}}function ue(e,t,n){{var i=C.ReactDebugCurrentFrame,_=i.getStackAddendum();_!==""&&(t+="%s",n=n.concat([_]));var v=n.map(function(k){return String(k)});v.unshift("Warning: "+t),Function.prototype.apply.call(console[e],console,v)}}var G=!1,Z=!1,fe=!1,J=!1,z=!1,Q;Q=Symbol.for("react.module.reference");function pe(e){return!!(typeof e=="string"||typeof e=="function"||e===c||e===a||z||e===f||e===N||e===y||J||e===S||G||Z||fe||typeof e=="object"&&e!==null&&(e.$$typeof===T||e.$$typeof===P||e.$$typeof===p||e.$$typeof===h||e.$$typeof===d||e.$$typeof===Q||e.getModuleId!==void 0))}function de(e,t,n){var i=e.displayName;if(i)return i;var _=t.displayName||t.name||"";return _!==""?n+"("+_+")":n}function K(e){return e.displayName||"Context"}function I(e){if(e==null)return null;if(typeof e.tag=="number"&&R("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case c:return"Fragment";case o:return"Portal";case a:return"Profiler";case f:return"StrictMode";case N:return"Suspense";case y:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case h:var t=e;return K(t)+".Consumer";case p:var n=e;return K(n._context)+".Provider";case d:return de(e,e.render,"ForwardRef");case P:var i=e.displayName||null;return i!==null?i:I(e.type)||"Memo";case T:{var _=e,v=_._payload,k=_._init;try{return I(k(v))}catch{return null}}}return null}var M=Object.assign,L=0,q,Y,me,ke,Oe,Fe,Ie;function De(){}De.__reactDisabledLog=!0;function dt(){{if(L===0){q=console.log,Y=console.info,me=console.warn,ke=console.error,Oe=console.group,Fe=console.groupCollapsed,Ie=console.groupEnd;var e={configurable:!0,enumerable:!0,value:De,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}L++}}function mt(){{if(L--,L===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:M({},e,{value:q}),info:M({},e,{value:Y}),warn:M({},e,{value:me}),error:M({},e,{value:ke}),group:M({},e,{value:Oe}),groupCollapsed:M({},e,{value:Fe}),groupEnd:M({},e,{value:Ie})})}L<0&&R("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var _e=C.ReactCurrentDispatcher,he;function ee(e,t,n){{if(he===void 0)try{throw Error()}catch(_){var i=_.stack.trim().match(/\n( *(at )?)/);he=i&&i[1]||""}return`
|
|
18
|
+
`+he+e}}var ve=!1,te;{var kt=typeof WeakMap=="function"?WeakMap:Map;te=new kt}function Ae(e,t){if(!e||ve)return"";{var n=te.get(e);if(n!==void 0)return n}var i;ve=!0;var _=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var v;v=_e.current,_e.current=null,dt();try{if(t){var k=function(){throw Error()};if(Object.defineProperty(k.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(k,[])}catch(W){i=W}Reflect.construct(e,[],k)}else{try{k.call()}catch(W){i=W}e.call(k.prototype)}}else{try{throw Error()}catch(W){i=W}e()}}catch(W){if(W&&i&&typeof W.stack=="string"){for(var m=W.stack.split(`
|
|
19
|
+
`),j=i.stack.split(`
|
|
20
|
+
`),x=m.length-1,w=j.length-1;x>=1&&w>=0&&m[x]!==j[w];)w--;for(;x>=1&&w>=0;x--,w--)if(m[x]!==j[w]){if(x!==1||w!==1)do if(x--,w--,w<0||m[x]!==j[w]){var O=`
|
|
21
|
+
`+m[x].replace(" at new "," at ");return e.displayName&&O.includes("<anonymous>")&&(O=O.replace("<anonymous>",e.displayName)),typeof e=="function"&&te.set(e,O),O}while(x>=1&&w>=0);break}}}finally{ve=!1,_e.current=v,mt(),Error.prepareStackTrace=_}var V=e?e.displayName||e.name:"",Ke=V?ee(V):"";return typeof e=="function"&&te.set(e,Ke),Ke}function _t(e,t,n){return Ae(e,!1)}function ht(e){var t=e.prototype;return!!(t&&t.isReactComponent)}function re(e,t,n){if(e==null)return"";if(typeof e=="function")return Ae(e,ht(e));if(typeof e=="string")return ee(e);switch(e){case N:return ee("Suspense");case y:return ee("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case d:return _t(e.render);case P:return re(e.type,t,n);case T:{var i=e,_=i._payload,v=i._init;try{return re(v(_),t,n)}catch{}}}return""}var ae=Object.prototype.hasOwnProperty,We={},Me=C.ReactDebugCurrentFrame;function ne(e){if(e){var t=e._owner,n=re(e.type,e._source,t?t.type:null);Me.setExtraStackFrame(n)}else Me.setExtraStackFrame(null)}function vt(e,t,n,i,_){{var v=Function.call.bind(ae);for(var k in e)if(v(e,k)){var m=void 0;try{if(typeof e[k]!="function"){var j=Error((i||"React class")+": "+n+" type `"+k+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[k]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw j.name="Invariant Violation",j}m=e[k](t,k,i,n,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(x){m=x}m&&!(m instanceof Error)&&(ne(_),R("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",i||"React class",n,k,typeof m),ne(null)),m instanceof Error&&!(m.message in We)&&(We[m.message]=!0,ne(_),R("Failed %s type: %s",n,m.message),ne(null))}}}var bt=Array.isArray;function be(e){return bt(e)}function gt(e){{var t=typeof Symbol=="function"&&Symbol.toStringTag,n=t&&e[Symbol.toStringTag]||e.constructor.name||"Object";return n}}function Nt(e){try{return Ye(e),!1}catch{return!0}}function Ye(e){return""+e}function $e(e){if(Nt(e))return R("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",gt(e)),Ye(e)}var X=C.ReactCurrentOwner,yt={key:!0,ref:!0,__self:!0,__source:!0},Le,Be,ge;ge={};function xt(e){if(ae.call(e,"ref")){var t=Object.getOwnPropertyDescriptor(e,"ref").get;if(t&&t.isReactWarning)return!1}return e.ref!==void 0}function Et(e){if(ae.call(e,"key")){var t=Object.getOwnPropertyDescriptor(e,"key").get;if(t&&t.isReactWarning)return!1}return e.key!==void 0}function Rt(e,t){if(typeof e.ref=="string"&&X.current&&t&&X.current.stateNode!==t){var n=I(X.current.type);ge[n]||(R('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',I(X.current.type),e.ref),ge[n]=!0)}}function wt(e,t){{var n=function(){Le||(Le=!0,R("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};n.isReactWarning=!0,Object.defineProperty(e,"key",{get:n,configurable:!0})}}function Pt(e,t){{var n=function(){Be||(Be=!0,R("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",t))};n.isReactWarning=!0,Object.defineProperty(e,"ref",{get:n,configurable:!0})}}var Tt=function(e,t,n,i,_,v,k){var m={$$typeof:s,type:e,key:t,ref:n,props:k,_owner:v};return m._store={},Object.defineProperty(m._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(m,"_self",{configurable:!1,enumerable:!1,writable:!1,value:i}),Object.defineProperty(m,"_source",{configurable:!1,enumerable:!1,writable:!1,value:_}),Object.freeze&&(Object.freeze(m.props),Object.freeze(m)),m};function Ct(e,t,n,i,_){{var v,k={},m=null,j=null;n!==void 0&&($e(n),m=""+n),Et(t)&&($e(t.key),m=""+t.key),xt(t)&&(j=t.ref,Rt(t,_));for(v in t)ae.call(t,v)&&!yt.hasOwnProperty(v)&&(k[v]=t[v]);if(e&&e.defaultProps){var x=e.defaultProps;for(v in x)k[v]===void 0&&(k[v]=x[v])}if(m||j){var w=typeof e=="function"?e.displayName||e.name||"Unknown":e;m&&wt(k,w),j&&Pt(k,w)}return Tt(e,m,j,_,i,X.current,k)}}var Ne=C.ReactCurrentOwner,Ve=C.ReactDebugCurrentFrame;function B(e){if(e){var t=e._owner,n=re(e.type,e._source,t?t.type:null);Ve.setExtraStackFrame(n)}else Ve.setExtraStackFrame(null)}var ye;ye=!1;function xe(e){return typeof e=="object"&&e!==null&&e.$$typeof===s}function Ue(){{if(Ne.current){var e=I(Ne.current.type);if(e)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+e+"`."}return""}}function jt(e){{if(e!==void 0){var t=e.fileName.replace(/^.*[\\\/]/,""),
|
|
23
|
+
Check the render method of \``+e+"`."}return""}}function jt(e){{if(e!==void 0){var t=e.fileName.replace(/^.*[\\\/]/,""),n=e.lineNumber;return`
|
|
24
24
|
|
|
25
|
-
Check your code at `+t+":"+
|
|
25
|
+
Check your code at `+t+":"+n+"."}return""}}var He={};function St(e){{var t=Ue();if(!t){var n=typeof e=="string"?e:e.displayName||e.name;n&&(t=`
|
|
26
26
|
|
|
27
|
-
Check the top-level render call using <`+a+">.")}return t}}function We(e,t){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var a=Ct(t);if(Ae[a])return;Ae[a]=!0;var i="";e&&e._owner&&e._owner!==oe.current&&(i=" It was passed a child from "+O(e._owner.type)+"."),A(e),P('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',a,i),A(null)}}function Ye(e,t){{if(typeof e!="object")return;if(ae(e))for(var a=0;a<e.length;a++){var i=e[a];se(i)&&We(i,t)}else if(se(e))e._store&&(e._store.validated=!0);else if(e){var h=H(e);if(typeof h=="function"&&h!==e.entries)for(var _=h.call(e),m;!(m=_.next()).done;)se(m.value)&&We(m.value,t)}}}function St(e){{var t=e.type;if(t==null||typeof t=="string")return;var a;if(typeof t=="function")a=t.propTypes;else if(typeof t=="object"&&(t.$$typeof===k||t.$$typeof===x))a=t.propTypes;else return;if(a){var i=O(t);_t(a,e.props,"prop",i,e)}else if(t.PropTypes!==void 0&&!le){le=!0;var h=O(t);P("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",h||"Unknown")}typeof t.getDefaultProps=="function"&&!t.getDefaultProps.isReactClassApproved&&P("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Ot(e){{for(var t=Object.keys(e.props),a=0;a<t.length;a++){var i=t[a];if(i!=="children"&&i!=="key"){A(e),P("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",i),A(null);break}}e.ref!==null&&(A(e),P("Invalid attribute `ref` supplied to `React.Fragment`."),A(null))}}function $e(e,t,a,i,h,_){{var m=ut(e);if(!m){var p="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(p+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var T=jt(h);T?p+=T:p+=Ie();var N;e===null?N="null":ae(e)?N="array":e!==void 0&&e.$$typeof===l?(N="<"+(O(e.type)||"Unknown")+" />",p=" Did you accidentally export a JSX literal instead of a component?"):N=typeof e,P("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",N,p)}var R=xt(e,t,a,h,_);if(R==null)return R;if(m){var j=t.children;if(j!==void 0)if(i)if(ae(j)){for(var W=0;W<j.length;W++)Ye(j[W],e);Object.freeze&&Object.freeze(j)}else P("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Ye(j,e)}return e===c?Ot(R):St(R),R}}function Ft(e,t,a){return $e(e,t,a,!0)}function Dt(e,t,a){return $e(e,t,a,!1)}var It=Dt,At=Ft;$.Fragment=c,$.jsx=It,$.jsxs=At}()),$}process.env.NODE_ENV==="production"?Z.exports=Le():Z.exports=Ve();var Q=Z.exports;const V=Q.Fragment,r=Q.jsx,f=Q.jsxs,q={},Ue='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32"></svg>';function He(o,l){return!q[o]&&typeof window.fetch=="function"&&(q[o]=window.fetch(l+o+".svg").then(s=>s.ok?s.text():(console.error("Missing icon: "+l+o+".svg"),Ue)).then(s=>s)),Promise.resolve(q[o])}const b=({name:o,path:l,className:s="",...c})=>{const u="https://punkt-cdn.oslo.kommune.no/5.1/icons/",[n,d]=E.useState(null);return E.useEffect(()=>{if(!o)return;He(o,l||u).then(k=>d(k))},[o,l,u]),n?r("span",{className:`pkt-icon ${s}`,dangerouslySetInnerHTML:{__html:n},...c}):null},Ge=E.forwardRef(({children:o,className:l,skin:s="info",closeAlert:c=!1,onClose:u,title:n,date:d,ariaLive:v="polite",...k},w)=>{const y=[l,"pkt-alert",s&&`pkt-alert--${s}`].filter(Boolean).join(" "),[x,C]=E.useState(!0),S=()=>{C(!1),u&&u()};return x?f("div",{...k,className:y,"aria-live":v,ref:w,children:[r(b,{className:"pkt-alert__icon",name:s==="info"?"alert-information":`alert-${s}`}),c&&r("div",{className:"pkt-alert__close",children:r("button",{type:"button",className:"pkt-btn pkt-btn--tertiary pkt-btn--small pkt-btn--icon-only",tabIndex:0,"aria-label":"close",onClick:S,children:r(b,{name:"close",className:"pkt-btn__icon","aria-hidden":"true"})})}),n&&r("div",{className:"pkt-alert__title",children:n}),r("div",{className:"pkt-alert__text",children:o}),d&&f("div",{className:"pkt-alert__date",children:["Sist oppdatert: ",d]})]}):null}),ue=E.forwardRef(({children:o,className:l,iconName:s="user",secondIconName:c="user",size:u="medium",skin:n="primary",type:d="button",variant:v="label-only",...k},w)=>{const y=[l,"pkt-btn",u&&`pkt-btn--${u}`,n&&`pkt-btn--${n}`,v&&`pkt-btn--${v}`].filter(Boolean).join(" ");return f("button",{...k,className:y,type:d,ref:w,children:[v!=="label-only"&&r(b,{className:"pkt-btn__icon",name:s}),r("span",{className:"pkt-btn__text",children:o}),v==="icons-right-and-left"&&r(b,{className:"pkt-btn__icon",name:c})]})});ue.displayName="PktButton";const Je=({columnOne:o,columnTwo:l,socialLinks:s})=>{var c,u;return r("footer",{className:"pkt-footer","data-mode":"dark",children:f("div",{className:"pkt-footer__container",children:[f("div",{className:"pkt-grid pkt-grid--rowgap-size-32 pkt-grid--gap-size-16",children:[f("div",{className:"pkt-footer__column pkt-cell pkt-cell--span12 pkt-cell--span4-laptop-up",children:[r("h2",{className:"pkt-footer__title",children:o.title}),f("ul",{className:"pkt-footer__list",children:[o.text&&r("li",{className:"pkt-footer__text",children:o.text}),(c=o.links)==null?void 0:c.map((n,d)=>r("li",{className:"pkt-footer__list-item",children:f("a",{className:`pkt-footer__link ${n.external?"pkt-link--external":""}`,href:n.href,target:n.openInNewTab?"_blank":"_self",rel:n.openInNewTab?"noopener noreferrer":void 0,children:[r(b,{className:"pkt-footer__link-icon",name:"chevron-right"}),n.text]})},`links-${d}`))]})]}),f("div",{className:"pkt-footer__column pkt-cell pkt-cell--span12 pkt-cell--span4-laptop-up",children:[r("h2",{className:"pkt-footer__title",children:l.title}),f("ul",{className:"pkt-footer__list",children:[l.text&&r("li",{className:"pkt-footer__text",children:l.text}),(u=l.links)==null?void 0:u.map((n,d)=>r("li",{className:"pkt-footer__list-item",children:f("a",{className:`pkt-footer__link ${n.external?"pkt-link--external":""}`,href:n.href,target:n.openInNewTab?"_blank":"_self",rel:n.openInNewTab?"noopener noreferrer":void 0,children:[r(b,{className:"pkt-footer__link-icon",name:"chevron-right"}),n.text]})},`links-${d}`))]})]}),f("div",{className:"pkt-footer__column pkt-cell pkt-cell--span12 pkt-cell--span4-laptop-up",children:[r("h2",{className:"pkt-footer__title",children:"Om nettstedet"}),f("ul",{className:"pkt-footer__list",children:[r("li",{className:"pkt-footer__list-item",children:f("a",{className:"pkt-footer__link",href:"https://www.oslo.kommune.no/personvern-og-informasjonskapsler/",children:[r(b,{className:"pkt-footer__link-icon",name:"chevron-right"}),"Personvern og informasjonskapsler"]})}),r("li",{className:"pkt-footer__list-item",children:f("a",{className:"pkt-footer__link",href:"https://www.oslo.kommune.no/tilgjengelighet/",children:[r(b,{className:"pkt-footer__link-icon",name:"chevron-right"}),"Tilgjengelighet"]})})]})]})]}),s&&f("div",{className:"pkt-footer__social","aria-label":"standard lenker",children:[r("div",{className:"pkt-footer__social-languages",children:s.filter(n=>n.language).map((n,d)=>r("div",{className:"pkt-footer__social-language",children:r("a",{href:n.href,"aria-label":`til ${n.language} versjon av nettsiden`,target:n.openInNewTab?"_blank":"_self",rel:n.openInNewTab?"noopener noreferrer":void 0,children:n.language})},`sociallinks-language-${d}`))}),r("div",{className:"pkt-footer__social-icons",children:s.filter(n=>n.iconName).map((n,d)=>r(E.Fragment,{children:r("a",{href:n.href,"aria-label":`til ${n.iconName}`,className:"pkt-footer__social-icon-link",target:n.openInNewTab?"_blank":"_self",rel:n.openInNewTab?"noopener noreferrer":void 0,children:r(b,{className:"pkt-footer__social-icon",name:n.iconName})})},`sociallinks-${d}`))})]})]})})},ze=({links:o=[]})=>r("footer",{className:"pkt-footer-simple","data-mode":"dark",children:r("div",{className:"pkt-footer-simple__container",children:f("ul",{className:"pkt-footer-simple__list",children:[o.map((l,s)=>r("li",{className:"pkt-footer-simple__list-item",children:f("a",{className:`pkt-footer-simple__link ${l.external?" pkt-link--external":""}`,href:l.href,target:l.openInNewTab?"_blank":"_self",rel:l.openInNewTab?"noopener noreferrer":void 0,children:[r(b,{className:"pkt-footer-simple__link-icon",name:"chevron-right"}),l.text]})},s)),r("li",{className:"pkt-footer-simple__list-item",children:f("a",{className:"pkt-footer-simple__link",href:"https://www.oslo.kommune.no/personvern-og-informasjonskapsler/",children:[r(b,{className:"pkt-footer-simple__link-icon",name:"chevron-right"}),"Personvern og informasjonskapsler"]})}),r("li",{className:"pkt-footer-simple__list-item",children:f("a",{className:"pkt-footer-simple__link",href:"https://www.oslo.kommune.no/tilgjengelighet/",children:[r(b,{className:"pkt-footer-simple__link-icon",name:"chevron-right"}),"Tilgjengelighet"]})})]})})}),Ke=({className:o,logoLink:l="https://www.oslo.kommune.no/",isLoggedIn:s=!1,representing:c="",canChangeRepresentation:u=!1,showLogInButton:n=!0,onLogIn:d,onLogOut:v,onChangeRepresentation:k})=>{const w=[o,"pkt-header"].filter(Boolean).join(" ");return f("header",{id:"pkt-header",className:w,"aria-label":"Topp",children:[r("div",{className:"pkt-header__logo",children:r("a",{"aria-label":"Tilbake til forside",className:"pkt-header__logo-link",href:l,children:r(b,{name:"oslologo",className:"pkt-header__logo-svg","aria-hidden":"true",path:"https://punkt-cdn.oslo.kommune.no/5.1/logos/"})})}),f("div",{className:"pkt-header__actions",children:[s&&u&&f("button",{className:"pkt-btn pkt-btn--secondary pkt-btn--icon-right","aria-label":`Bytt bruker fra ${c}`,onClick:k,children:[r(b,{name:"user",className:"pkt-btn__icon pkt-show-tablet-up"}),r("span",{className:"pkt-header__action-change pkt-hide pkt-show-tablet-up ml-size-15",children:"Endre"}),r("span",{className:"pkt-btn__text pkt-hide-tablet-up",children:"Endre"}),r("span",{className:"pkt-btn__text--representing pkt-hide pkt-show-tablet-up",children:c})]}),s&&!u&&f("div",{className:"pkt-header__action",children:[r("span",{className:"pkt-header__action-text",children:r("span",{className:"pkt-btn__text pkt-header__action-textrow text-row-inline pkt-truncate-text",children:c})}),r(b,{className:"pkt-header__action-icon pkt-show-phablet-up",name:"user"})]}),n&&s&&f("button",{className:"pkt-btn pkt-btn--tertiary pkt-btn--icon-right","aria-label":"Logg ut",onClick:v,children:[r(b,{className:"pkt-btn__icon pkt-show-tablet-up",name:"exit"}),r("span",{className:"pkt-btn__text",children:"Logg ut"})]}),n&&!s&&f("button",{className:"pkt-btn pkt-btn--tertiary pkt-btn--icon-right","aria-label":"Logg inn",onClick:d,children:[r(b,{className:"pkt-btn__icon",name:"user"}),r("span",{className:"pkt-btn__text",children:"Logg inn"})]})]})]})},fe=E.forwardRef(({label:o,id:l,children:s,...c},u)=>f("div",{className:"pkt-form-group",children:[r("label",{htmlFor:l,className:"pkt-form-label",children:o}),r("input",{className:"pkt-form-input",id:l,...c,ref:u}),s]}));fe.displayName="PktInput";const pe=E.forwardRef(({children:o,className:l,iconName:s="user",openInNewTab:c=!1,skin:u="normal",href:n="#",external:d=!1,title:v},k)=>{const w=[l,"pkt-linkcard",u&&`pkt-linkcard--${u}`].filter(Boolean).join(" ");return f("a",{href:n,className:`pkt-linkcard pkt-link ${w}`,target:c?"_blank":"_self",rel:c?"noopener noreferrer":void 0,ref:k,children:[r(b,{className:"pkt-link__icon",name:s}),f("div",{className:"pkt-linkcard__content",children:[r("div",{className:`pkt-linkcard__title ${d?"pkt-link pkt-link--external":""}`,children:v}),r("div",{className:"pkt-linkcard__text",children:o})]})]})});pe.displayName="PktLinkCard";const Xe=({children:o,skin:l="beige",title:s,...c})=>{const u=["pkt-messagebox",l&&`pkt-messagebox--${l}`].filter(Boolean).join(" ");return f("div",{...c,className:u,children:[r("div",{className:"pkt-messagebox__title",children:s}),r("div",{className:"pkt-messagebox__text",children:o})]})},de=E.forwardRef(({id:o,name:l,label:s,value:c,...u},n)=>f("div",{className:"pkt-form-group",children:[r("input",{type:"radio",className:"pkt-form-check-input",id:o,name:l,value:c,ref:n,...u}),r("label",{className:"pkt-form-label",htmlFor:o,children:s})]}));de.displayName="PktRadio";const Ze=({label:o,children:l})=>f(V,{children:[r("p",{children:o}),r("div",{className:"pkt-form-group",children:l})]});var me={exports:{}};/*!
|
|
27
|
+
Check the top-level render call using <`+n+">.")}return t}}function Ge(e,t){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var n=St(t);if(He[n])return;He[n]=!0;var i="";e&&e._owner&&e._owner!==Ne.current&&(i=" It was passed a child from "+I(e._owner.type)+"."),B(e),R('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',n,i),B(null)}}function Je(e,t){{if(typeof e!="object")return;if(be(e))for(var n=0;n<e.length;n++){var i=e[n];xe(i)&&Ge(i,t)}else if(xe(e))e._store&&(e._store.validated=!0);else if(e){var _=A(e);if(typeof _=="function"&&_!==e.entries)for(var v=_.call(e),k;!(k=v.next()).done;)xe(k.value)&&Ge(k.value,t)}}}function Ot(e){{var t=e.type;if(t==null||typeof t=="string")return;var n;if(typeof t=="function")n=t.propTypes;else if(typeof t=="object"&&(t.$$typeof===d||t.$$typeof===P))n=t.propTypes;else return;if(n){var i=I(t);vt(n,e.props,"prop",i,e)}else if(t.PropTypes!==void 0&&!ye){ye=!0;var _=I(t);R("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",_||"Unknown")}typeof t.getDefaultProps=="function"&&!t.getDefaultProps.isReactClassApproved&&R("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Ft(e){{for(var t=Object.keys(e.props),n=0;n<t.length;n++){var i=t[n];if(i!=="children"&&i!=="key"){B(e),R("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",i),B(null);break}}e.ref!==null&&(B(e),R("Invalid attribute `ref` supplied to `React.Fragment`."),B(null))}}function ze(e,t,n,i,_,v){{var k=pe(e);if(!k){var m="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(m+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var j=jt(_);j?m+=j:m+=Ue();var x;e===null?x="null":be(e)?x="array":e!==void 0&&e.$$typeof===s?(x="<"+(I(e.type)||"Unknown")+" />",m=" Did you accidentally export a JSX literal instead of a component?"):x=typeof e,R("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",x,m)}var w=Ct(e,t,n,_,v);if(w==null)return w;if(k){var O=t.children;if(O!==void 0)if(i)if(be(O)){for(var V=0;V<O.length;V++)Je(O[V],e);Object.freeze&&Object.freeze(O)}else R("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Je(O,e)}return e===c?Ft(w):Ot(w),w}}function It(e,t,n){return ze(e,t,n,!0)}function Dt(e,t,n){return ze(e,t,n,!1)}var At=Dt,Wt=It;H.Fragment=c,H.jsx=At,H.jsxs=Wt}()),H}process.env.NODE_ENV==="production"?le.exports=Ze():le.exports=Qe();var se=le.exports;const $=se.Fragment,r=se.jsx,u=se.jsxs,oe={},qe='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32"></svg>';function et(l,s){return!oe[l]&&typeof window.fetch=="function"&&(oe[l]=window.fetch(s+l+".svg").then(o=>o.ok?o.text():(console.error("Missing icon: "+s+l+".svg"),qe)).then(o=>o)),Promise.resolve(oe[l])}const b=({name:l,path:s,className:o="",...c})=>{const f="https://punkt-cdn.oslo.kommune.no/5.2/icons/",[a,p]=E.useState(null);return E.useEffect(()=>{if(!l)return;et(l,s||f).then(d=>p(d))},[l,s,f]),a?r("span",{className:`pkt-icon ${o}`,dangerouslySetInnerHTML:{__html:a},...c}):null},ie=E.forwardRef(({children:l,className:s,skin:o="info",closeAlert:c=!1,onClose:f,title:a,date:p,ariaLive:h="polite",...d},N)=>{const y=[s,"pkt-alert",o&&`pkt-alert--${o}`].filter(Boolean).join(" "),[P,T]=E.useState(!0),S=()=>{T(!1),f&&f()};return P?u("div",{...d,className:y,"aria-live":h,ref:N,children:[r(b,{className:"pkt-alert__icon",name:o==="info"?"alert-information":`alert-${o}`}),c&&r("div",{className:"pkt-alert__close",children:r("button",{type:"button",className:"pkt-btn pkt-btn--tertiary pkt-btn--small pkt-btn--icon-only",tabIndex:0,"aria-label":"close",onClick:S,children:r(b,{name:"close",className:"pkt-btn__icon","aria-hidden":"true"})})}),a&&r("div",{className:"pkt-alert__title",children:a}),r("div",{className:"pkt-alert__text",children:l}),p&&u("div",{className:"pkt-alert__date",children:["Sist oppdatert: ",p]})]}):null}),ce=E.forwardRef(({children:l,className:s,iconName:o="user",secondIconName:c="user",size:f="medium",skin:a="primary",type:p="button",variant:h="label-only",...d},N)=>{const y=[s,"pkt-btn",f&&`pkt-btn--${f}`,a&&`pkt-btn--${a}`,h&&`pkt-btn--${h}`].filter(Boolean).join(" ");return u("button",{...d,className:y,type:p,ref:N,children:[h!=="label-only"&&r(b,{className:"pkt-btn__icon",name:o}),r("span",{className:"pkt-btn__text",children:l}),h==="icons-right-and-left"&&r(b,{className:"pkt-btn__icon",name:c})]})});ce.displayName="PktButton";const tt=({columnOne:l,columnTwo:s,socialLinks:o})=>{var c,f;return r("footer",{className:"pkt-footer","data-mode":"dark",children:u("div",{className:"pkt-footer__container",children:[u("div",{className:"pkt-grid pkt-grid--rowgap-size-32 pkt-grid--gap-size-16",children:[u("div",{className:"pkt-footer__column pkt-cell pkt-cell--span12 pkt-cell--span4-laptop-up",children:[r("h2",{className:"pkt-footer__title",children:l.title}),u("ul",{className:"pkt-footer__list",children:[l.text&&r("li",{className:"pkt-footer__text",children:l.text}),(c=l.links)==null?void 0:c.map((a,p)=>r("li",{className:"pkt-footer__list-item",children:u("a",{className:`pkt-footer__link ${a.external?"pkt-link--external":""}`,href:a.href,target:a.openInNewTab?"_blank":"_self",rel:a.openInNewTab?"noopener noreferrer":void 0,children:[r(b,{className:"pkt-footer__link-icon",name:"chevron-right"}),a.text]})},`links-${p}`))]})]}),u("div",{className:"pkt-footer__column pkt-cell pkt-cell--span12 pkt-cell--span4-laptop-up",children:[r("h2",{className:"pkt-footer__title",children:s.title}),u("ul",{className:"pkt-footer__list",children:[s.text&&r("li",{className:"pkt-footer__text",children:s.text}),(f=s.links)==null?void 0:f.map((a,p)=>r("li",{className:"pkt-footer__list-item",children:u("a",{className:`pkt-footer__link ${a.external?"pkt-link--external":""}`,href:a.href,target:a.openInNewTab?"_blank":"_self",rel:a.openInNewTab?"noopener noreferrer":void 0,children:[r(b,{className:"pkt-footer__link-icon",name:"chevron-right"}),a.text]})},`links-${p}`))]})]}),u("div",{className:"pkt-footer__column pkt-cell pkt-cell--span12 pkt-cell--span4-laptop-up",children:[r("h2",{className:"pkt-footer__title",children:"Om nettstedet"}),u("ul",{className:"pkt-footer__list",children:[r("li",{className:"pkt-footer__list-item",children:u("a",{className:"pkt-footer__link",href:"https://www.oslo.kommune.no/personvern-og-informasjonskapsler/",children:[r(b,{className:"pkt-footer__link-icon",name:"chevron-right"}),"Personvern og informasjonskapsler"]})}),r("li",{className:"pkt-footer__list-item",children:u("a",{className:"pkt-footer__link",href:"https://www.oslo.kommune.no/tilgjengelighet/",children:[r(b,{className:"pkt-footer__link-icon",name:"chevron-right"}),"Tilgjengelighet"]})})]})]})]}),o&&u("div",{className:"pkt-footer__social","aria-label":"standard lenker",children:[r("div",{className:"pkt-footer__social-languages",children:o.filter(a=>a.language).map((a,p)=>r("div",{className:"pkt-footer__social-language",children:r("a",{href:a.href,"aria-label":`til ${a.language} versjon av nettsiden`,target:a.openInNewTab?"_blank":"_self",rel:a.openInNewTab?"noopener noreferrer":void 0,children:a.language})},`sociallinks-language-${p}`))}),r("div",{className:"pkt-footer__social-icons",children:o.filter(a=>a.iconName).map((a,p)=>r(E.Fragment,{children:r("a",{href:a.href,"aria-label":`til ${a.iconName}`,className:"pkt-footer__social-icon-link",target:a.openInNewTab?"_blank":"_self",rel:a.openInNewTab?"noopener noreferrer":void 0,children:r(b,{className:"pkt-footer__social-icon",name:a.iconName})})},`sociallinks-${p}`))})]})]})})},rt=({links:l=[]})=>r("footer",{className:"pkt-footer-simple","data-mode":"dark",children:r("div",{className:"pkt-footer-simple__container",children:u("ul",{className:"pkt-footer-simple__list",children:[l.map((s,o)=>r("li",{className:"pkt-footer-simple__list-item",children:u("a",{className:`pkt-footer-simple__link ${s.external?" pkt-link--external":""}`,href:s.href,target:s.openInNewTab?"_blank":"_self",rel:s.openInNewTab?"noopener noreferrer":void 0,children:[r(b,{className:"pkt-footer-simple__link-icon",name:"chevron-right"}),s.text]})},o)),r("li",{className:"pkt-footer-simple__list-item",children:u("a",{className:"pkt-footer-simple__link",href:"https://www.oslo.kommune.no/personvern-og-informasjonskapsler/",children:[r(b,{className:"pkt-footer-simple__link-icon",name:"chevron-right"}),"Personvern og informasjonskapsler"]})}),r("li",{className:"pkt-footer-simple__list-item",children:u("a",{className:"pkt-footer-simple__link",href:"https://www.oslo.kommune.no/tilgjengelighet/",children:[r(b,{className:"pkt-footer-simple__link-icon",name:"chevron-right"}),"Tilgjengelighet"]})})]})})}),at=({className:l,logoLink:s="https://www.oslo.kommune.no/",isLoggedIn:o=!1,representing:c="",canChangeRepresentation:f=!1,showLogInButton:a=!0,onLogIn:p,onLogOut:h,onChangeRepresentation:d})=>{const N=[l,"pkt-header"].filter(Boolean).join(" ");return u("header",{id:"pkt-header",className:N,"aria-label":"Topp",children:[r("div",{className:"pkt-header__logo",children:r("a",{"aria-label":"Tilbake til forside",className:"pkt-header__logo-link",href:s,children:r(b,{name:"oslologo",className:"pkt-header__logo-svg","aria-hidden":"true",path:"https://punkt-cdn.oslo.kommune.no/5.2/logos/"})})}),u("div",{className:"pkt-header__actions",children:[o&&f&&u("button",{className:"pkt-btn pkt-btn--secondary pkt-btn--icon-right","aria-label":`Bytt bruker fra ${c}`,onClick:d,children:[r(b,{name:"user",className:"pkt-btn__icon pkt-show-tablet-up"}),r("span",{className:"pkt-header__action-change pkt-hide pkt-show-tablet-up ml-size-15",children:"Endre"}),r("span",{className:"pkt-btn__text pkt-hide-tablet-up",children:"Endre"}),r("span",{className:"pkt-btn__text--representing pkt-hide pkt-show-tablet-up",children:c})]}),o&&!f&&u("div",{className:"pkt-header__action",children:[r("span",{className:"pkt-header__action-text",children:r("span",{className:"pkt-btn__text pkt-header__action-textrow text-row-inline pkt-truncate-text",children:c})}),r(b,{className:"pkt-header__action-icon pkt-show-phablet-up",name:"user"})]}),a&&o&&u("button",{className:"pkt-btn pkt-btn--tertiary pkt-btn--icon-right","aria-label":"Logg ut",onClick:h,children:[r(b,{className:"pkt-btn__icon pkt-show-tablet-up",name:"exit"}),r("span",{className:"pkt-btn__text",children:"Logg ut"})]}),a&&!o&&u("button",{className:"pkt-btn pkt-btn--tertiary pkt-btn--icon-right","aria-label":"Logg inn",onClick:p,children:[r(b,{className:"pkt-btn__icon",name:"user"}),r("span",{className:"pkt-btn__text",children:"Logg inn"})]})]})]})},we=E.forwardRef(({label:l,id:s,children:o,...c},f)=>u("div",{className:"pkt-form-group",children:[r("label",{htmlFor:s,className:"pkt-form-label",children:l}),r("input",{className:"pkt-form-input",id:s,...c,ref:f}),o]}));we.displayName="PktInput";const Pe=E.forwardRef(({children:l,className:s,iconName:o="user",openInNewTab:c=!1,skin:f="normal",href:a="#",external:p=!1,title:h},d)=>{const N=[s,"pkt-linkcard",f&&`pkt-linkcard--${f}`].filter(Boolean).join(" ");return u("a",{href:a,className:`pkt-linkcard pkt-link ${N}`,target:c?"_blank":"_self",rel:c?"noopener noreferrer":void 0,ref:d,children:[r(b,{className:"pkt-link__icon",name:o}),u("div",{className:"pkt-linkcard__content",children:[r("div",{className:`pkt-linkcard__title ${p?"pkt-link pkt-link--external":""}`,children:h}),r("div",{className:"pkt-linkcard__text",children:l})]})]})});Pe.displayName="PktLinkCard";const nt=({children:l,skin:s="beige",title:o,...c})=>{const f=["pkt-messagebox",s&&`pkt-messagebox--${s}`].filter(Boolean).join(" ");return u("div",{...c,className:f,children:[r("div",{className:"pkt-messagebox__title",children:o}),r("div",{className:"pkt-messagebox__text",children:l})]})},Te=E.forwardRef(({id:l,name:s,label:o,value:c,...f},a)=>u("div",{className:"pkt-form-group",children:[r("input",{type:"radio",className:"pkt-form-check-input",id:l,name:s,value:c,ref:a,...f}),r("label",{className:"pkt-form-label",htmlFor:l,children:o})]}));Te.displayName="PktRadio";const lt=({label:l,children:s})=>u($,{children:[r("p",{children:l}),r("div",{className:"pkt-form-group",children:s})]});var Ce={exports:{}};/*!
|
|
28
28
|
Copyright (c) 2018 Jed Watson.
|
|
29
29
|
Licensed under the MIT License (MIT), see
|
|
30
30
|
http://jedwatson.github.io/classnames
|
|
31
|
-
*/(function(
|
|
31
|
+
*/(function(l){(function(){var s={}.hasOwnProperty;function o(){for(var c=[],f=0;f<arguments.length;f++){var a=arguments[f];if(a){var p=typeof a;if(p==="string"||p==="number")c.push(a);else if(Array.isArray(a)){if(a.length){var h=o.apply(null,a);h&&c.push(h)}}else if(p==="object"){if(a.toString!==Object.prototype.toString&&!a.toString.toString().includes("[native code]")){c.push(a.toString());continue}for(var d in a)s.call(a,d)&&a[d]&&c.push(d)}}}return c.join(" ")}l.exports?(o.default=o,l.exports=o):window.classNames=o})()})(Ce);var st=Ce.exports;const ot=Xe(st),it=({isResponsive:l,children:s})=>l?r("div",{className:"pkt-table-container",children:s}):r($,{children:s}),ct=({isResponsive:l,modifiers:{info:s=!1,success:o=!1,strong:c=!1,shadow:f=!1}={},children:a})=>r(it,{isResponsive:l,children:r("table",{className:ot("pkt-table",{"pkt-table--info":s,"pkt-table--success":o,"pkt-table--strong":c,"pkt-table--shadow":f}),children:a})}),ut=({children:l})=>r("td",{className:"pkt-table__th",children:l}),ft=({children:l})=>r("th",{className:"pkt-table__th",children:l}),je=E.forwardRef(({children:l,className:s,skin:o="blue",textStyle:c="normal-text",size:f="medium",closeTag:a=!1,iconName:p="",type:h="button",ariaLabel:d="close",onClick:N=()=>{}},y)=>{const[P,T]=E.useState(!1),S=C=>{T(!0),N(C)},D=["pkt-tag",f&&`pkt-tag--${f}`,o&&`pkt-tag--${o}`,c&&`pkt-tag--${c}`,s].filter(Boolean).join(" "),F=["pkt-tag","pkt-btn","pkt-btn--tertiary",f&&`pkt-tag--${f}`,o&&`pkt-tag--${o}`,c&&`pkt-tag--${c}`,p&&a?"pkt-btn--icons-right-and-left":null,a&&!p?"pkt-btn--icon-right":null,s].filter(Boolean).join(" "),A=!P;return a&&p?r($,{children:A&&u("button",{className:F,type:h,"aria-label":d,onClick:S,ref:y,children:[r(b,{className:"pkt-tag__icon",name:p}),l,r(b,{className:"pkt-tag__close-btn",name:"close"})]})}):a?r($,{children:A&&u("button",{className:F,type:h,"aria-label":d,onClick:S,ref:y,children:[r(b,{className:"pkt-tag__close-btn",name:"close"}),l]})}):p?u("span",{className:D,children:[r(b,{className:"pkt-tag__icon",name:p}),l]}):r("span",{className:D,children:l})});je.displayName="PktTag";const Se=E.forwardRef(({id:l,label:s,...o},c)=>u("div",{className:"pkt-form-group",children:[r("label",{htmlFor:l,className:"pkt-form-label",children:s}),r("textarea",{className:"pkt-form-textarea",id:l,ref:c,...o})]}));Se.displayName="PktTextarea";const pt=E.forwardRef(({id:l,label:s,name:o,srOnlyLabel:c=!1,helptext:f,helptextDropdown:a,helptextDropdownButton:p,optional:h=!1,required:d=!1,hasError:N=!1,errorMessage:y,placeholder:P,type:T="text",autocomplete:S="off",value:D,suffix:F,prefix:A,iconNameRight:C,disabled:R=!1,inline:ue=!1,ariaLabelledby:G,ariaDescribedby:Z,className:fe},J)=>{const[z,Q]=E.useState(!1),pe=()=>{Q(!z)},de=()=>h?"pkt-tag pkt-tag--small pkt-tag--thin-text pkt-tag--blue-light":d?"pkt-tag pkt-tag--small pkt-tag--thin-text pkt-tag--beige":"",K=h?"Valgfritt":d?"Må fylles ut":"",q=[fe,"pkt-textinput",R?"pkt-textinput--disabled":"",ue?"pkt-textinput--inline":"",N?"pkt-textinput--error":""].join(" "),Y=!!a&&a!=="";return u("div",{className:q,children:[u(Y?"div":"label",{htmlFor:l,className:`pkt-textinput__label ${c?"pkt-sr-only":""}`,"aria-describedby":Y?"":Z,children:[u(Y?"h2":"span",{children:[s,K!==""&&r("span",{className:de(),children:K})]}),f&&r("div",{className:"pkt-textinput__helptext",children:f}),Y&&u($,{children:[r(ce,{skin:"tertiary",size:"small",variant:"icon-right",iconName:z?"chevron-thin-up":"chevron-thin-down",className:"pkt-textinput__helptext-expandable pkt-link pkt-link--icon-right",onClick:pe,children:p||u($,{children:["Les mer ",r("span",{className:"pkt-sr-only",children:"om inputfeltet"})]})}),r("div",{className:`pkt-textinput__helptext ${z?"pkt-textinput__helptext-expandable-open":"pkt-textinput__helptext-expandable-closed"}`,children:r(ie,{children:a})}),r("label",{htmlFor:l,className:"pkt-textinput__label pkt-sr-only","aria-describedby":Z,children:s})]}),A&&u("div",{className:"pkt-textinput__input-prefix-wrapper",children:[r("div",{className:"pkt-textinput__input-prefix",children:A}),r("input",{ref:J,className:"pkt-textinput__input",type:T,name:o||l,id:l,placeholder:P,autoComplete:S,value:D,disabled:R,"aria-required":d,"aria-invalid":N,"aria-labelledby":G})]}),!A&&(F||C)&&u("div",{className:"pkt-textinput__input-suffix-wrapper",children:[r("input",{ref:J,className:"pkt-textinput__input",type:T,name:o||l,id:l,placeholder:P,autoComplete:S,value:D,disabled:R,"aria-required":d,"aria-invalid":N,"aria-labelledby":G}),F&&u("p",{className:"pkt-textinput__input-suffix",children:[F,C&&r(b,{className:"pkt-textinput__input-suffix-icon",name:C})]}),!F&&C&&r(b,{className:"pkt-textinput__input-icon",name:C})]}),!A&&!F&&!C&&!a&&r("input",{ref:J,className:"pkt-textinput__input",type:T,name:o||l,id:l,placeholder:P,autoComplete:S,value:D,disabled:R,"aria-required":d,"aria-invalid":N,"aria-labelledby":G})]}),N&&r(ie,{skin:"error","aria-live":"assertive",children:y})]})});g.PktAlert=ie,g.PktButton=ce,g.PktFooter=tt,g.PktFooterSimple=rt,g.PktHeader=at,g.PktIcon=b,g.PktInput=we,g.PktLinkCard=Pe,g.PktMessagebox=nt,g.PktRadio=Te,g.PktRadioGroup=lt,g.PktTable=ct,g.PktTableData=ut,g.PktTableHeader=ft,g.PktTag=je,g.PktTextarea=Se,g.PktTextinput=pt,Object.defineProperty(g,Symbol.toStringTag,{value:"Module"})});
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface IPktTextinput extends React.InputHTMLAttributes<HTMLInputElement> {
|
|
3
|
+
id: string;
|
|
4
|
+
label: string;
|
|
5
|
+
name?: string;
|
|
6
|
+
srOnlyLabel?: boolean;
|
|
7
|
+
helptext?: string;
|
|
8
|
+
helptextDropdown?: string;
|
|
9
|
+
helptextDropdownButton?: string;
|
|
10
|
+
optional?: boolean;
|
|
11
|
+
required?: boolean;
|
|
12
|
+
hasError?: boolean;
|
|
13
|
+
errorMessage?: string;
|
|
14
|
+
placeholder?: string;
|
|
15
|
+
type?: string;
|
|
16
|
+
autocomplete?: string;
|
|
17
|
+
value?: string;
|
|
18
|
+
suffix?: string;
|
|
19
|
+
prefix?: string;
|
|
20
|
+
iconNameRight?: string;
|
|
21
|
+
disabled?: boolean;
|
|
22
|
+
inline?: boolean;
|
|
23
|
+
ariaLabelledby?: string;
|
|
24
|
+
ariaDescribedby?: string;
|
|
25
|
+
}
|
|
26
|
+
export declare const PktTextinput: React.ForwardRefExoticComponent<IPktTextinput & React.RefAttributes<HTMLInputElement>>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oslokommune/punkt-react",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.2.0",
|
|
4
4
|
"description": "React komponentbibliotek til Punkt, et designsystem laget av Oslo Origo",
|
|
5
5
|
"homepage": "https://punkt.oslo.kommune.no",
|
|
6
6
|
"author": "Team Designsystem, Oslo Origo",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
34
|
"@oslokommune/punkt-assets": "^5.1.19",
|
|
35
|
-
"@oslokommune/punkt-css": "^5.
|
|
35
|
+
"@oslokommune/punkt-css": "^5.2.0",
|
|
36
36
|
"@testing-library/jest-dom": "^5.16.5",
|
|
37
37
|
"@testing-library/react": "^14.0.0",
|
|
38
38
|
"@testing-library/user-event": "^14.4.3",
|
|
@@ -90,5 +90,5 @@
|
|
|
90
90
|
"url": "https://github.com/oslokommune/punkt/issues"
|
|
91
91
|
},
|
|
92
92
|
"license": "MIT",
|
|
93
|
-
"gitHead": "
|
|
93
|
+
"gitHead": "fec1858cd2fa9d95724dbe6bff7b64cac4dfa540"
|
|
94
94
|
}
|
|
@@ -57,64 +57,64 @@ describe('PktFooterSimple', () => {
|
|
|
57
57
|
|
|
58
58
|
|
|
59
59
|
describe('basic rendering', () => {
|
|
60
|
-
|
|
61
|
-
|
|
60
|
+
it('should render columns and social links', () => {
|
|
61
|
+
render(<PktFooter columnOne={columnOne} columnTwo={columnTwo} socialLinks={socialLinks} />)
|
|
62
62
|
|
|
63
|
-
|
|
64
|
-
|
|
63
|
+
const columnOneElement = screen.getByText('Column One')
|
|
64
|
+
expect(columnOneElement).toBeInTheDocument()
|
|
65
65
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
66
|
+
const columnOneLink1Element = screen.getByText('Link 1')
|
|
67
|
+
expect(columnOneLink1Element).toHaveAttribute('href', 'https://example.com')
|
|
68
|
+
expect(columnOneLink1Element).toHaveClass('pkt-link--external')
|
|
69
69
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
70
|
+
const columnOneLink2Element = screen.getByText('Link 2')
|
|
71
|
+
expect(columnOneLink2Element).toHaveAttribute('href', 'https://example.com')
|
|
72
|
+
expect(columnOneLink2Element).not.toHaveClass('pkt-link--external')
|
|
73
73
|
|
|
74
|
-
|
|
75
|
-
|
|
74
|
+
const columnOneTextElement = screen.getByText('Column One Text')
|
|
75
|
+
expect(columnOneTextElement).toBeInTheDocument()
|
|
76
76
|
|
|
77
|
-
|
|
78
|
-
|
|
77
|
+
const columnTwoElement = screen.getByText('Column Two')
|
|
78
|
+
expect(columnTwoElement).toBeInTheDocument()
|
|
79
79
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
80
|
+
const columnTwoLink3Element = screen.getByText('Link 3')
|
|
81
|
+
expect(columnTwoLink3Element).toHaveAttribute('href', 'https://example.com')
|
|
82
|
+
expect(columnTwoLink3Element).toHaveClass('pkt-link--external')
|
|
83
83
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
84
|
+
const columnTwoLink4Element = screen.getByText('Link 4')
|
|
85
|
+
expect(columnTwoLink4Element).toHaveAttribute('href', 'https://example.com')
|
|
86
|
+
expect(columnTwoLink4Element).not.toHaveClass('pkt-link--external')
|
|
87
87
|
|
|
88
|
-
|
|
89
|
-
|
|
88
|
+
const columnTwoTextElement = screen.getByText('Column Two Text')
|
|
89
|
+
expect(columnTwoTextElement).toBeInTheDocument()
|
|
90
90
|
|
|
91
|
-
|
|
92
|
-
|
|
91
|
+
const personvernLink = screen.getByText('Personvern og informasjonskapsler');
|
|
92
|
+
expect(personvernLink).toBeInTheDocument();
|
|
93
93
|
|
|
94
|
-
|
|
95
|
-
|
|
94
|
+
const tilgjengelighetLink = screen.getByText('Tilgjengelighet');
|
|
95
|
+
expect(tilgjengelighetLink).toBeInTheDocument();
|
|
96
96
|
|
|
97
|
-
|
|
98
|
-
|
|
97
|
+
const socialLinksElement = screen.getByLabelText('standard lenker')
|
|
98
|
+
expect(socialLinksElement).toBeInTheDocument()
|
|
99
99
|
|
|
100
|
-
|
|
101
|
-
|
|
100
|
+
const socialLinksFacebookElement = screen.getByLabelText('til facebook')
|
|
101
|
+
expect(socialLinksFacebookElement).toHaveAttribute('href', 'https://example.com')
|
|
102
102
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
103
|
+
const socialLinksTwitterElement = screen.getByLabelText('til twitter')
|
|
104
|
+
expect(socialLinksTwitterElement).toHaveAttribute('href', 'https://example.com')
|
|
105
|
+
})
|
|
106
106
|
})
|
|
107
107
|
|
|
108
108
|
describe('accessibility', () => {
|
|
109
109
|
it('renders with no wcag errors with axe', async () => {
|
|
110
|
-
const { container } = render(<PktFooter columnOne={columnOne} columnTwo={columnTwo} socialLinks={socialLinks}/>);
|
|
110
|
+
const { container } = render(<PktFooter columnOne={columnOne} columnTwo={columnTwo} socialLinks={socialLinks} />);
|
|
111
111
|
const results = await axe(container);
|
|
112
112
|
expect(results).toHaveNoViolations();
|
|
113
113
|
})
|
|
114
114
|
})
|
|
115
115
|
|
|
116
116
|
describe('snapshot', () => {
|
|
117
|
-
it('renders correctly', () => {
|
|
117
|
+
it('renders correctly with all props', () => {
|
|
118
118
|
const { container } = render(<PktFooter columnOne={columnOne} columnTwo={columnTwo} socialLinks={socialLinks} />);
|
|
119
119
|
expect(container).toMatchSnapshot();
|
|
120
120
|
})
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
-
exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
3
|
+
exports[`PktFooterSimple snapshot renders correctly with all props 1`] = `
|
|
4
4
|
<div>
|
|
5
5
|
<footer
|
|
6
6
|
class="pkt-footer"
|
|
@@ -34,15 +34,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
34
34
|
<a
|
|
35
35
|
class="pkt-footer__link pkt-link--external"
|
|
36
36
|
href="https://example.com"
|
|
37
|
+
target="_self"
|
|
37
38
|
>
|
|
38
|
-
<svg
|
|
39
|
-
class="pkt-footer__link-icon"
|
|
40
|
-
viewBox="0 0 32 32"
|
|
41
|
-
>
|
|
42
|
-
<use
|
|
43
|
-
href="#chevron-right"
|
|
44
|
-
/>
|
|
45
|
-
</svg>
|
|
46
39
|
Link 1
|
|
47
40
|
</a>
|
|
48
41
|
</li>
|
|
@@ -52,15 +45,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
52
45
|
<a
|
|
53
46
|
class="pkt-footer__link "
|
|
54
47
|
href="https://example.com"
|
|
48
|
+
target="_self"
|
|
55
49
|
>
|
|
56
|
-
<svg
|
|
57
|
-
class="pkt-footer__link-icon"
|
|
58
|
-
viewBox="0 0 32 32"
|
|
59
|
-
>
|
|
60
|
-
<use
|
|
61
|
-
href="#chevron-right"
|
|
62
|
-
/>
|
|
63
|
-
</svg>
|
|
64
50
|
Link 2
|
|
65
51
|
</a>
|
|
66
52
|
</li>
|
|
@@ -88,15 +74,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
88
74
|
<a
|
|
89
75
|
class="pkt-footer__link pkt-link--external"
|
|
90
76
|
href="https://example.com"
|
|
77
|
+
target="_self"
|
|
91
78
|
>
|
|
92
|
-
<svg
|
|
93
|
-
class="pkt-footer__link-icon"
|
|
94
|
-
viewBox="0 0 32 32"
|
|
95
|
-
>
|
|
96
|
-
<use
|
|
97
|
-
href="#chevron-right"
|
|
98
|
-
/>
|
|
99
|
-
</svg>
|
|
100
79
|
Link 3
|
|
101
80
|
</a>
|
|
102
81
|
</li>
|
|
@@ -106,15 +85,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
106
85
|
<a
|
|
107
86
|
class="pkt-footer__link "
|
|
108
87
|
href="https://example.com"
|
|
88
|
+
target="_self"
|
|
109
89
|
>
|
|
110
|
-
<svg
|
|
111
|
-
class="pkt-footer__link-icon"
|
|
112
|
-
viewBox="0 0 32 32"
|
|
113
|
-
>
|
|
114
|
-
<use
|
|
115
|
-
href="#chevron-right"
|
|
116
|
-
/>
|
|
117
|
-
</svg>
|
|
118
90
|
Link 4
|
|
119
91
|
</a>
|
|
120
92
|
</li>
|
|
@@ -138,14 +110,6 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
138
110
|
class="pkt-footer__link"
|
|
139
111
|
href="https://www.oslo.kommune.no/personvern-og-informasjonskapsler/"
|
|
140
112
|
>
|
|
141
|
-
<svg
|
|
142
|
-
class="pkt-footer__link-icon"
|
|
143
|
-
viewBox="0 0 32 32"
|
|
144
|
-
>
|
|
145
|
-
<use
|
|
146
|
-
href="#chevron-right"
|
|
147
|
-
/>
|
|
148
|
-
</svg>
|
|
149
113
|
Personvern og informasjonskapsler
|
|
150
114
|
</a>
|
|
151
115
|
</li>
|
|
@@ -156,14 +120,6 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
156
120
|
class="pkt-footer__link"
|
|
157
121
|
href="https://www.oslo.kommune.no/tilgjengelighet/"
|
|
158
122
|
>
|
|
159
|
-
<svg
|
|
160
|
-
class="pkt-footer__link-icon"
|
|
161
|
-
viewBox="0 0 32 32"
|
|
162
|
-
>
|
|
163
|
-
<use
|
|
164
|
-
href="#chevron-right"
|
|
165
|
-
/>
|
|
166
|
-
</svg>
|
|
167
123
|
Tilgjengelighet
|
|
168
124
|
</a>
|
|
169
125
|
</li>
|
|
@@ -184,32 +140,14 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
184
140
|
aria-label="til facebook"
|
|
185
141
|
class="pkt-footer__social-icon-link"
|
|
186
142
|
href="https://example.com"
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
aria-hidden="true"
|
|
190
|
-
class="pkt-footer__social-icon"
|
|
191
|
-
viewBox="0 0 32 32"
|
|
192
|
-
>
|
|
193
|
-
<use
|
|
194
|
-
href="#facebook"
|
|
195
|
-
/>
|
|
196
|
-
</svg>
|
|
197
|
-
</a>
|
|
143
|
+
target="_self"
|
|
144
|
+
/>
|
|
198
145
|
<a
|
|
199
146
|
aria-label="til twitter"
|
|
200
147
|
class="pkt-footer__social-icon-link"
|
|
201
148
|
href="https://example.com"
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
aria-hidden="true"
|
|
205
|
-
class="pkt-footer__social-icon"
|
|
206
|
-
viewBox="0 0 32 32"
|
|
207
|
-
>
|
|
208
|
-
<use
|
|
209
|
-
href="#twitter"
|
|
210
|
-
/>
|
|
211
|
-
</svg>
|
|
212
|
-
</a>
|
|
149
|
+
target="_self"
|
|
150
|
+
/>
|
|
213
151
|
</div>
|
|
214
152
|
</div>
|
|
215
153
|
</div>
|
|
@@ -58,7 +58,7 @@ describe('PktFooterSimple', () => {
|
|
|
58
58
|
})
|
|
59
59
|
|
|
60
60
|
describe('snapshot', () => {
|
|
61
|
-
it('renders correctly', () => {
|
|
61
|
+
it('renders correctly with all props', () => {
|
|
62
62
|
const { container } = render(<PktFooterSimple links={links} />);
|
|
63
63
|
expect(container).toMatchSnapshot();
|
|
64
64
|
})
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
-
exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
3
|
+
exports[`PktFooterSimple snapshot renders correctly with all props 1`] = `
|
|
4
4
|
<div>
|
|
5
5
|
<footer
|
|
6
6
|
class="pkt-footer-simple"
|
|
@@ -18,15 +18,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
18
18
|
<a
|
|
19
19
|
class="pkt-footer-simple__link "
|
|
20
20
|
href="https://www.example.com"
|
|
21
|
+
target="_self"
|
|
21
22
|
>
|
|
22
|
-
<svg
|
|
23
|
-
class="pkt-footer-simple__link-icon"
|
|
24
|
-
viewBox="0 0 32 32"
|
|
25
|
-
>
|
|
26
|
-
<use
|
|
27
|
-
href="#chevron-right"
|
|
28
|
-
/>
|
|
29
|
-
</svg>
|
|
30
23
|
Example Link 1
|
|
31
24
|
</a>
|
|
32
25
|
</li>
|
|
@@ -36,15 +29,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
36
29
|
<a
|
|
37
30
|
class="pkt-footer-simple__link "
|
|
38
31
|
href="https://www.example.com"
|
|
32
|
+
target="_self"
|
|
39
33
|
>
|
|
40
|
-
<svg
|
|
41
|
-
class="pkt-footer-simple__link-icon"
|
|
42
|
-
viewBox="0 0 32 32"
|
|
43
|
-
>
|
|
44
|
-
<use
|
|
45
|
-
href="#chevron-right"
|
|
46
|
-
/>
|
|
47
|
-
</svg>
|
|
48
34
|
Example Link 2
|
|
49
35
|
</a>
|
|
50
36
|
</li>
|
|
@@ -54,15 +40,8 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
54
40
|
<a
|
|
55
41
|
class="pkt-footer-simple__link "
|
|
56
42
|
href="https://www.example.com"
|
|
43
|
+
target="_self"
|
|
57
44
|
>
|
|
58
|
-
<svg
|
|
59
|
-
class="pkt-footer-simple__link-icon"
|
|
60
|
-
viewBox="0 0 32 32"
|
|
61
|
-
>
|
|
62
|
-
<use
|
|
63
|
-
href="#chevron-right"
|
|
64
|
-
/>
|
|
65
|
-
</svg>
|
|
66
45
|
Example Link 3
|
|
67
46
|
</a>
|
|
68
47
|
</li>
|
|
@@ -73,14 +52,6 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
73
52
|
class="pkt-footer-simple__link"
|
|
74
53
|
href="https://www.oslo.kommune.no/personvern-og-informasjonskapsler/"
|
|
75
54
|
>
|
|
76
|
-
<svg
|
|
77
|
-
class="pkt-footer-simple__link-icon"
|
|
78
|
-
viewBox="0 0 32 32"
|
|
79
|
-
>
|
|
80
|
-
<use
|
|
81
|
-
href="#chevron-right"
|
|
82
|
-
/>
|
|
83
|
-
</svg>
|
|
84
55
|
Personvern og informasjonskapsler
|
|
85
56
|
</a>
|
|
86
57
|
</li>
|
|
@@ -91,14 +62,6 @@ exports[`PktFooterSimple snapshot renders correctly 1`] = `
|
|
|
91
62
|
class="pkt-footer-simple__link"
|
|
92
63
|
href="https://www.oslo.kommune.no/tilgjengelighet/"
|
|
93
64
|
>
|
|
94
|
-
<svg
|
|
95
|
-
class="pkt-footer-simple__link-icon"
|
|
96
|
-
viewBox="0 0 32 32"
|
|
97
|
-
>
|
|
98
|
-
<use
|
|
99
|
-
href="#chevron-right"
|
|
100
|
-
/>
|
|
101
|
-
</svg>
|
|
102
65
|
Tilgjengelighet
|
|
103
66
|
</a>
|
|
104
67
|
</li>
|
package/src/components/index.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export { PktAlert } from './alert/Alert'
|
|
2
2
|
export { PktButton } from './button/Button'
|
|
3
|
-
export { PktFooter} from './footer/Footer'
|
|
4
|
-
export { PktFooterSimple} from './footerSimple/FooterSimple'
|
|
3
|
+
export { PktFooter } from './footer/Footer'
|
|
4
|
+
export { PktFooterSimple } from './footerSimple/FooterSimple'
|
|
5
5
|
export { PktHeader } from './header/Header'
|
|
6
6
|
export { PktIcon } from './icon/Icon'
|
|
7
7
|
export { PktInput } from './input/Input'
|
|
@@ -14,4 +14,4 @@ export { PktTableData } from './table/TableData'
|
|
|
14
14
|
export { PktTableHeader } from './table/TableHeader'
|
|
15
15
|
export { PktTag } from './tag/Tag'
|
|
16
16
|
export { PktTextarea } from './textarea/Textarea'
|
|
17
|
-
|
|
17
|
+
export { PktTextinput } from './textinput/Textinput'
|
|
@@ -66,7 +66,7 @@ describe('PktLinkCard', () => {
|
|
|
66
66
|
})
|
|
67
67
|
|
|
68
68
|
describe('snapshots', () => {
|
|
69
|
-
it('renders correctly as fragment', () => {
|
|
69
|
+
it('renders correctly as fragment with props', () => {
|
|
70
70
|
const { asFragment } = render(
|
|
71
71
|
<PktLinkCard title="Link title" href="/example">
|
|
72
72
|
Link content
|