UNPKG

@salesforce-ux/design-system

Version:
1 lines 6.36 kB
var SLDS;!function(){"use strict";var e,t={1594:function(e){e.exports=React},2184:function(e,t,n){n.r(t),n.d(t,{examples:function(){return f}});var a=n(1594),i=n.n(a),l=n(6333),o=n.n(l),s=n(6955),r=n(8522),c=n(942),m=n.n(c),d=function(e){return i().createElement("div",{className:"slds-notification-container"},e.children)},u=function(e){var t=o()("dialog-body-id-"),n=o()("noti-");return i().createElement("section",{className:"slds-notification",role:"dialog","aria-labelledby":n,"aria-describedby":t},i().createElement("div",{className:"slds-notification__body",id:t},i().createElement("a",{className:"slds-notification__target slds-media",href:"#",onClick:function(e){return e.preventDefault()}},i().createElement(r.StandardIcon,{containerClassName:"slds-media__figure",className:"slds-icon_small",symbol:e.type,title:e.type}),i().createElement("div",{className:"slds-media__body"},i().createElement("h2",{className:"slds-text-heading_small slds-m-bottom_xx-small",id:n},i().createElement("span",{className:"slds-assistive-text"},"".concat(e.type," notification:")),e.title),i().createElement("p",null,e.description))),i().createElement(s.A,{className:"slds-button_icon-container slds-notification__close",symbol:"close",assistiveText:"Dismiss ".concat(e.title," notification"),title:"Dismiss ".concat(e.title," notification")})),e.footer&&i().createElement("footer",{className:m()("slds-notification__footer",e.footerClassName)},e.footer))};t.default=[{id:"default",label:"Default",element:i().createElement("div",{className:"demo-only demo-only_viewport",style:{height:"4.5rem"}},i().createElement(d,null,i().createElement("div",{"aria-live":"assertive","aria-atomic":"true",className:"slds-assistive-text"},"event notification: Tesla - Renewal meeting"),i().createElement(u,{type:"event",title:"Tesla - Renewal meeting",description:"Event at 11:00am on Jan 8"})))}];var f=[{id:"task-notification",label:"Task Notification",element:i().createElement("div",{className:"demo-only demo-only_viewport",style:{height:"4.5rem"}},i().createElement(d,null,i().createElement("div",{"aria-live":"assertive","aria-atomic":"true",className:"slds-assistive-text"},"task notification: Call: Jane Johnson"),i().createElement(u,{type:"task",title:"Call: Jane Johnson",description:"Task due on Jan 8"})))},{id:"stacked-2",label:"Stacked Notifications",element:i().createElement("div",{className:"demo-only demo-only_viewport",style:{height:"15rem"}},i().createElement(d,null,i().createElement("div",{"aria-live":"assertive","aria-atomic":"true",className:"slds-assistive-text"},"task notification: Call One: Jane Johnson"),i().createElement(u,{type:"task",title:"Call One: Jane Johnson",description:"Task due on Jan 8"}),i().createElement(u,{type:"event",title:"Call Two: Tesla - Renewal meeting",description:"Event at 11:00am on Jan 8"})))},{id:"stacked-3",label:"Three Stacked Notifications",element:i().createElement("div",{className:"demo-only demo-only_viewport",style:{height:"15rem"}},i().createElement(d,null,i().createElement("div",{"aria-live":"assertive","aria-atomic":"true",className:"slds-assistive-text"},"task notification: Call Two: Jane Johnson"),i().createElement(u,{type:"task",title:"Call Two: Jane Johnson",description:"Task due on Jan 8"}),i().createElement(u,{type:"event",title:"Call Three: Tesla - Renewal meeting",description:"Event at 11:00am on Jan 8"}),i().createElement(u,{type:"task",title:"Call Four: Jim Jameson",description:"Task due on Jan 8"})))},{id:"overflow-six",label:"Six Stacked Notifications",element:i().createElement("div",{className:"demo-only demo-only_viewport",style:{height:"17rem"}},i().createElement(d,null,i().createElement("div",{"aria-live":"assertive","aria-atomic":"true",className:"slds-assistive-text"},"task notification: Call Five: Jane Johnson"),i().createElement(u,{type:"task",title:"Call Five: Jane Johnson",description:"Task due on Jan 8"}),i().createElement(u,{type:"event",title:"Call Six: Tesla - Renewal meeting",description:"Event at 11:00am on Jan 8"}),i().createElement(u,{type:"task",title:"Call Seven: Jim Jameson",description:"Task due on Jan 8"}),i().createElement(u,{type:"task",title:"Call Eight: Jane Johnson",description:"Task due on Jan 8"}),i().createElement(u,{type:"event",title:"Call Nine: Tesla - Renewal meeting",description:"Event at 11:00am on Jan 8"}),i().createElement(u,{type:"task",title:"Call Ten: Jim Jameson",description:"Task due on Jan 8"})))}]}},n={};function a(e){var i=n[e];if(void 0!==i)return i.exports;var l=n[e]={exports:{}};return t[e](l,l.exports,a),l.exports}a.m=t,a.amdO={},e=[],a.O=function(t,n,i,l){if(!n){var o=1/0;for(m=0;m<e.length;m++){n=e[m][0],i=e[m][1],l=e[m][2];for(var s=!0,r=0;r<n.length;r++)(!1&l||o>=l)&&Object.keys(a.O).every(function(e){return a.O[e](n[r])})?n.splice(r--,1):(s=!1,l<o&&(o=l));if(s){e.splice(m--,1);var c=i();void 0!==c&&(t=c)}}return t}l=l||0;for(var m=e.length;m>0&&e[m-1][2]>l;m--)e[m]=e[m-1];e[m]=[n,i,l]},a.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(t,{a:t}),t},a.d=function(e,t){for(var n in t)a.o(t,n)&&!a.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},a.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),a.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.j=5154,function(){var e={518:0,1117:0,1252:0,1578:0,1974:0,2033:0,2274:0,2782:0,3140:0,4268:0,4583:0,4723:0,4924:0,5154:0,6671:0,7217:0,7257:0,7385:0,7508:0,8167:0,8458:0};a.O.j=function(t){return 0===e[t]};var t=function(t,n){var i,l,o=n[0],s=n[1],r=n[2],c=0;if(o.some(function(t){return 0!==e[t]})){for(i in s)a.o(s,i)&&(a.m[i]=s[i]);if(r)var m=r(a)}for(t&&t(n);c<o.length;c++)l=o[c],a.o(e,l)&&e[l]&&e[l][0](),e[l]=0;return a.O(m)},n=self.webpackJsonpSLDS___internal_chunked_showcase=self.webpackJsonpSLDS___internal_chunked_showcase||[];n.forEach(t.bind(null,0)),n.push=t.bind(null,n.push.bind(n))}(),a.nc=void 0;var i=a.O(void 0,[6790],function(){return a(2184)});i=a.O(i),(SLDS=void 0===SLDS?{}:SLDS)["__internal/chunked/showcase/./ui/components/notifications/base/example.jsx.js"]=i}();