@fluid-topics/ft-icon 0.1.6 → 0.1.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.
@@ -0,0 +1,41 @@
1
+ !function(e,t,a,o,x){var i,p;e.FtIcons=void 0,(i=e.FtIcons||(e.FtIcons={})).THIN_ARROW_LEFT="&#xe956;",i.THIN_ARROW_RIGHT="&#xe957;",i.MY_COLLECTIONS="&#xe955;",i.OFFLINE_SETTINGS="&#xe954;",i.MY_LIBRARY="&#xe959;",i.RATE_PLAIN="&#xe952;",i.RATE="&#xe953;",i.FEEDBACK_PLAIN="&#xe951;",i.STAR_PLAIN="&#xe94b;",i.STAR="&#xe94c;",i.THUMBS_DOWN_PLAIN="&#xe94d;",i.THUMBS_DOWN="&#xe94e;",i.THUMBS_UP_PLAIN="&#xe94f;",i.THUMBS_UP="&#xe950;",i.PAUSE="&#xe949;",i.PLAY="&#xe94a;",i.RELATIVES_PLAIN="&#xe947;",i.RELATIVES="&#xe948;",i.SHORTCUT_MENU="&#xe946;",i.PRINT="&#xe944;",i.DEFAULT_ROLES="&#xe945;",i.ACCOUNT_SETTINGS="&#xe943;",i.ONLINE="&#xe941;",i.OFFLINE="&#xe816;",i.UPLOAD="&#xe940;",i.BOOK_PLAIN="&#xe93f;",i.SYNC="&#xe93d;",i.SHARED_PBK="&#xe931;",i.COLLECTIONS="&#xe92a;",i.SEARCH_IN_PUBLICATION="&#xe92f;",i.BOOKS="&#xe806;",i.LOCKER="&#xe93b;",i.ARROW_DOWN="&#xe92b;",i.ARROW_LEFT="&#xe92c;",i.ARROW_RIGHT="&#xe92d;",i.ARROW_UP="&#xe92e;",i.SAVE="&#xe93a;",i.MAILS_AND_NOTIFICATIONS="&#xe939;",i.DOT="&#xe936;",i.MINUS="&#xe937;",i.PLUS="&#xe938;",i.FILTERS="&#xe935;",i.STRIPE_ARROW_RIGHT="&#xe934;",i.STRIPE_ARROW_LEFT="&#xe933;",i.ATTACHMENTS="&#xe932;",i.ADD_BOOKMARK="&#xe804;",i.BOOKMARK="&#xe805;",i.EXPORT="&#xe80f;",i.MENU="&#xe807;",i.TAG="&#xe93e;",i.TAG_PLAIN="&#xe942;",i.COPY_TO_CLIPBOARD="&#xe930;",i.COLUMNS="&#xe928;",i.ARTICLE="&#xe927;",i.CLOSE_PLAIN="&#xe925;",i.CHECK_PLAIN="&#xe926;",i.LOGOUT="&#xe923;",i.SIGN_IN="&#xe922;",i.THIN_ARROW="&#xe921;",i.TRIANGLE_BOTTOM="&#xe91d;",i.TRIANGLE_LEFT="&#xe91e;",i.TRIANGLE_RIGHT="&#xe91f;",i.TRIANGLE_TOP="&#xe920;",i.FACET_HAS_DESCENDANT="&#xe91c;",i.MINUS_PLAIN="&#xe91a;",i.PLUS_PLAIN="&#xe91b;",i.INFO="&#xe919;",i.ICON_EXPAND="&#xe917;",i.ICON_COLLAPSE="&#xe918;",i.ADD_TO_PBK="&#xe800;",i.ALERT="&#xe801;",i.ADD_ALERT="&#xe802;",i.BACK_TO_SEARCH="&#xe803;",i.DOWNLOAD="&#xe808;",i.EDIT="&#xe809;",i.FEEDBACK="&#xe80a;",i.MODIFY_PBK="&#xe80c;",i.SCHEDULED="&#xe80d;",i.SEARCH="&#xe80e;",i.SHARE="&#xe80f1;",i.TOC="&#xe810;",i.WRITE_UGC="&#xe811;",i.TRASH="&#xe812;",i.EXTLINK="&#xe814;",i.CALENDAR="&#xe815;",i.BOOK="&#xe817;",i.DOWNLOAD_PLAIN="&#xe818;",i.CHECK="&#xe819;",i.TOPICS="&#xe900;",i.EYE="\f06e",i.DISC="&#xe901;",i.CIRCLE="&#xe903;",i.SHARED="&#xe904;",i.SORT_UNSORTED="&#xe905;",i.SORT_UP="&#xe906;",i.SORT_DOWN="&#xe907;",i.WORKING="&#xe908;",i.CLOSE="&#xe909;",i.ZOOM_OUT="&#xe90a;",i.ZOOM_IN="&#xe90b;",i.ZOOM_REALSIZE="&#xe90c;",i.ZOOM_FULLSCREEN="&#xe90d;",i.ADMIN_RESTRICTED="&#xe90e;",i.ADMIN_THEME="&#xe911;",i.WARNING="&#xe913;",i.CONTEXT="&#xe914;",i.SEARCH_HOME="&#xe915;",i.STEPS="&#xe916;",i.HOME="&#xe80b;",i.TRANSLATE="&#xe924;",i.USER="&#xe813;",i.ADMIN="&#xe902;",i.ANALYTICS="&#xe929;",i.ADMIN_KHUB="&#xe90f;",i.ADMIN_USERS="&#xe910;",i.ADMIN_INTEGRATION="&#xe93c;",i.ADMIN_PORTAL="&#xe912;",e.FtFileFormatIcons=void 0,(p=e.FtFileFormatIcons||(e.FtFileFormatIcons={})).UNKNOWN="&#xe90a;",p.ABW="&#xe900;",p.AUDIO="&#xe901;",p.AVI="&#xe902;",p.CHM="&#xe904;",p.CODE="&#xe905;",p.CSV="&#xe903;",p.DITA="&#xe906;",p.EPUB="&#xe907;",p.EXCEL="&#xe908;",p.FLAC="&#xe909;",p.GIF="&#xe90b;",p.GZIP="&#xe90c;",p.HTML="&#xe90d;",p.IMAGE="&#xe90e;",p.JPEG="&#xe90f;",p.JSON="&#xe910;",p.M4A="&#xe911;",p.MOV="&#xe912;",p.MP3="&#xe913;",p.MP4="&#xe914;",p.OGG="&#xe915;",p.PDF="&#xe916;",p.PNG="&#xe917;",p.POWERPOINT="&#xe918;",p.RAR="&#xe91a;",p.STP="&#xe91b;",p.TEXT="&#xe91c;",p.VIDEO="&#xe91e;",p.WAV="&#xe91f;",p.WMA="&#xe920;",p.WORD="&#xe921;",p.XML="&#xe922;",p.YAML="&#xe919;",p.ZIP="&#xe923;";const n=new Map([...["abw"].map((t=>[t,e.FtFileFormatIcons.ABW])),...["3gp","act","aiff","aac","amr","au","awb","dct","dss","dvf","gsm","iklax","ivs","mmf","mpc","msv","opus","ra","rm","raw","sln","tta","vox","wv"].map((t=>[t,e.FtFileFormatIcons.AUDIO])),...["avi"].map((t=>[t,e.FtFileFormatIcons.AVI])),...["chm","xhs"].map((t=>[t,e.FtFileFormatIcons.CHM])),...["java","py","php","php3","php4","php5","js","javascript","rb","rbw","c","cpp","cxx","h","hh","hpp","hxx","sh","bash","zsh","tcsh","ksh","csh","vb","scala","pl","prl","perl","groovy","ceylon","aspx","jsp","scpt","applescript","bas","bat","lua","jsp","mk","cmake","css","sass","less","m","mm","xcodeproj"].map((t=>[t,e.FtFileFormatIcons.CODE])),...["csv"].map((t=>[t,e.FtFileFormatIcons.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,e.FtFileFormatIcons.DITA])),...["epub"].map((t=>[t,e.FtFileFormatIcons.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,e.FtFileFormatIcons.EXCEL])),...["flac"].map((t=>[t,e.FtFileFormatIcons.FLAC])),...["gif"].map((t=>[t,e.FtFileFormatIcons.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,e.FtFileFormatIcons.GZIP])),...["html","htm","xhtml"].map((t=>[t,e.FtFileFormatIcons.HTML])),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf"].map((t=>[t,e.FtFileFormatIcons.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,e.FtFileFormatIcons.JPEG])),...["json"].map((t=>[t,e.FtFileFormatIcons.JSON])),...["m4a","m4p"].map((t=>[t,e.FtFileFormatIcons.M4A])),...["mov","qt"].map((t=>[t,e.FtFileFormatIcons.MOV])),...["mp3"].map((t=>[t,e.FtFileFormatIcons.MP3])),...["mp4","m4v"].map((t=>[t,e.FtFileFormatIcons.MP4])),...["ogg","oga"].map((t=>[t,e.FtFileFormatIcons.OGG])),...["pdf","ps"].map((t=>[t,e.FtFileFormatIcons.PDF])),...["png"].map((t=>[t,e.FtFileFormatIcons.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,e.FtFileFormatIcons.POWERPOINT])),...["rar"].map((t=>[t,e.FtFileFormatIcons.RAR])),...["stp"].map((t=>[t,e.FtFileFormatIcons.STP])),...["txt","rtf","md","mdown"].map((t=>[t,e.FtFileFormatIcons.TEXT])),...["webm","mkv","flv","vob","ogv","ogg","drc","mng","wmv","yuv","rm","rmvb","asf","mpg","mp2","mpeg","mpe","mpv","m2v","svi","3gp","3g2","mxf","roq","nsv"].map((t=>[t,e.FtFileFormatIcons.VIDEO])),...["wav"].map((t=>[t,e.FtFileFormatIcons.WAV])),...["wma"].map((t=>[t,e.FtFileFormatIcons.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,e.FtFileFormatIcons.WORD])),...["xml","xsl","rdf"].map((t=>[t,e.FtFileFormatIcons.XML])),...["yaml","yml","x-yaml"].map((t=>[t,e.FtFileFormatIcons.YAML])),...["zip"].map((t=>[t,e.FtFileFormatIcons.ZIP]))]),l=new Map([["application/msword","application/doc"],["application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/docx"],["application/vnd.openxmlformats-officedocument.wordprocessingml.template","application/dotx"],["application/vnd.ms-word.document.macroEnabled.12","application/docm"],["application/vnd.ms-word.template.macroEnabled.12","application/dotm"],["application/vnd.ms-excel","application/xls"],["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/xlsx"],["application/vnd.openxmlformats-officedocument.spreadsheetml.template","application/xltx"],["application/vnd.ms-excel.sheet.macroEnabled.12","application/xlsm"],["application/vnd.ms-excel.template.macroEnabled.12","application/xltm"],["application/vnd.ms-excel.addin.macroEnabled.12","application/xlam"],["application/vnd.ms-excel.sheet.binary.macroEnabled.12","application/xlsb"],["application/vnd.ms-powerpoint","application/ppt"],["application/vnd.openxmlformats-officedocument.presentationml.presentation","application/pptx"],["application/vnd.openxmlformats-officedocument.presentationml.template","application/potx"],["application/vnd.openxmlformats-officedocument.presentationml.slideshow","application/ppsx"],["application/vnd.ms-powerpoint.addin.macroEnabled.12","application/ppam"],["application/vnd.ms-powerpoint.presentation.macroEnabled.12","application/pptm"],["application/vnd.ms-powerpoint.template.macroEnabled.12","application/potm"],["application/vnd.ms-powerpoint.slideshow.macroEnabled.12","application/ppsm"],["application/vnd.ms-access","application/mdb"]]);var s,m=function(e,t,a,o){for(var x,i=arguments.length,p=i<3?t:null===o?o=Object.getOwnPropertyDescriptor(t,a):o,n=e.length-1;n>=0;n--)(x=e[n])&&(p=(i<3?x(p):i>3?x(t,a,p):x(t,a))||p);return i>3&&p&&Object.defineProperty(t,a,p),p};e.FtIconVariants=void 0,(s=e.FtIconVariants||(e.FtIconVariants={})).fluid_topics="fluid-topics",s.file_format="file-format";const c={size:o.FtCssVariable.create("--ft-icon-font-size","SIZE","24px"),fluidTopicsFontFamily:o.FtCssVariable.extend("--ft-icon-fluid-topics-font-family",o.FtCssVariable.create("--ft-icon-font-family","UNKNOWN","ft-icons")),fileFormatFontFamily:o.FtCssVariable.extend("--ft-icon-file-format-font-family",o.FtCssVariable.create("--ft-icon-font-family","UNKNOWN","ft-mime"))},d=t.css`
2
+ .ft-icon--fluid-topics {
3
+ font-family: ${c.fluidTopicsFontFamily}, ft-icons, fticons, sans-serif;
4
+ font-size: ${c.size};
5
+ line-height: 1;
6
+ font-weight: normal;
7
+ text-transform: none;
8
+ font-style: normal;
9
+ font-variant: normal;
10
+ speak: none;
11
+ text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.004);
12
+ text-rendering: auto;
13
+ -webkit-font-smoothing: antialiased;
14
+ -moz-osx-font-smoothing: grayscale;
15
+ }
16
+ `,f=t.css`
17
+ .ft-icon--file-format {
18
+ font-family: ${c.fileFormatFontFamily}, ft-mime, sans-serif;
19
+ font-size: ${c.size};
20
+ line-height: 1;
21
+ font-weight: normal;
22
+ text-transform: none;
23
+ font-style: normal;
24
+ font-variant: normal;
25
+ speak: none;
26
+ text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.004);
27
+ text-rendering: auto;
28
+ -webkit-font-smoothing: antialiased;
29
+ -moz-osx-font-smoothing: grayscale;
30
+ }
31
+ `;e.FtIcon=class extends o.FtLitElement{constructor(){super(...arguments),this.variant=e.FtIconVariants.fluid_topics}getStyles(){return[d,f,t.css`
32
+ :host, i.ft-icon {
33
+ display: inline-block;
34
+ width: ${c.size};
35
+ height: ${c.size};
36
+ text-align: center;
37
+ }
38
+ `]}getTemplate(){return t.html`
39
+ <slot @slotchange=${()=>this.requestUpdate()} hidden></slot>
40
+ <i class="ft-icon ${"ft-icon--"+this.variant}">${x.unsafeHTML(this.getIcon())}</i>
41
+ `}get textContent(){var e,t;return null!==(t=null===(e=this.slottedContent)||void 0===e?void 0:e.assignedNodes().map((e=>e.textContent)).join("").trim())&&void 0!==t?t:""}getIcon(){var t,a;return this.variant===e.FtIconVariants.file_format?null!==(t=e.FtFileFormatIcons[this.textContent.toUpperCase()])&&void 0!==t?t:this.textContent:null!==(a=e.FtIcons[this.textContent.toUpperCase()])&&void 0!==a?a:this.textContent}},e.FtIcon.elementDefinitions={},m([a.property()],e.FtIcon.prototype,"variant",void 0),m([a.query("slot")],e.FtIcon.prototype,"slottedContent",void 0),e.FtIcon=m([o.customElement("ft-icon")],e.FtIcon),e.FtIconCssVariables=c,e.FtIconFileFormat=f,e.FtIconFluidTopics=d,e.resolveFileFormatIcon=function(t,a){var o,x,i,p;t=(null!=t?t:"").toLowerCase(),a=(null!=a?a:"").toLowerCase();const[s,m]=((null!==(o=l.get(t))&&void 0!==o?o:t)+"/").split("/");return null!==(p=null!==(i=null!==(x=n.get(m))&&void 0!==x?x:n.get(a))&&void 0!==i?i:n.get(s))&&void 0!==p?p:e.FtFileFormatIcons.UNKNOWN},Object.defineProperty(e,"t",{value:!0})}({},ftGlobals.lit,ftGlobals.litDecorators,ftGlobals.wcUtils,ftGlobals.litUnsafeHTML);
@@ -39,7 +39,21 @@ var it;null===(it=window.HTMLSlotElement)||void 0===it||it.prototype.assignedEle
39
39
  * Copyright 2021 Google LLC
40
40
  * SPDX-License-Identifier: BSD-3-Clause
41
41
  */
42
- function(t){return class extends t{createRenderRoot(){const t=this.constructor,{registry:e,elementDefinitions:i,shadowRootOptions:n}=t;i&&!e&&(t.registry=new CustomElementRegistry,Object.entries(i).forEach((([e,i])=>t.registry.define(e,i))));const o=this.renderOptions.creationScope=this.attachShadow({...n,customElements:t.registry});return a(o,this.constructor.elementStyles),o}}}(Y)){constructor(){super(),this.constructorName=this.constructor.name,this.proto=this.constructor.prototype}getStyles(){return[]}getTemplate(){return null}render(){let t=this.getStyles();return Array.isArray(t)||(t=[t]),A`${t.map((t=>A`<style>${t}</style>`))} ${this.getTemplate()}`}adoptedCallback(){Object.getPrototypeOf(this)!==this.constructorName&&Object.setPrototypeOf(this,this.proto)}updated(t){super.updated(t),setTimeout((()=>this.contentAvailableCallback(t)),0)}contentAvailableCallback(t){}}var st,rt;r`.ft-no-text-select{-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}`,navigator.vendor&&navigator.vendor.match(/apple/i)||(null===(rt=null===(st=window.safari)||void 0===st?void 0:st.pushNotification)||void 0===rt||rt.toString());
42
+ function(t){return class extends t{createRenderRoot(){const t=this.constructor,{registry:e,elementDefinitions:i,shadowRootOptions:n}=t;i&&!e&&(t.registry=new CustomElementRegistry,Object.entries(i).forEach((([e,i])=>t.registry.define(e,i))));const o=this.renderOptions.creationScope=this.attachShadow({...n,customElements:t.registry});return a(o,this.constructor.elementStyles),o}}}(Y)){constructor(){super(),this.constructorName=this.constructor.name,this.proto=this.constructor.prototype}getStyles(){return[]}getTemplate(){return null}render(){let t=this.getStyles();return Array.isArray(t)||(t=[t]),A`
43
+ ${t.map((t=>A`
44
+ <style>${t}</style>
45
+ `))}
46
+ ${this.getTemplate()}
47
+ `}adoptedCallback(){Object.getPrototypeOf(this)!==this.constructorName&&Object.setPrototypeOf(this,this.proto)}updated(t){super.updated(t),setTimeout((()=>this.contentAvailableCallback(t)),0)}contentAvailableCallback(t){}}var st,rt;r`
48
+ .ft-no-text-select {
49
+ -webkit-touch-callout: none;
50
+ -webkit-user-select: none;
51
+ -khtml-user-select: none;
52
+ -moz-user-select: none;
53
+ -ms-user-select: none;
54
+ user-select: none;
55
+ }
56
+ `,navigator.vendor&&navigator.vendor.match(/apple/i)||(null===(rt=null===(st=window.safari)||void 0===st?void 0:st.pushNotification)||void 0===rt||rt.toString());
43
57
  /**
44
58
  * @license
45
59
  * Copyright 2017 Google LLC
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluid-topics/ft-icon",
3
- "version": "0.1.6",
3
+ "version": "0.1.7",
4
4
  "description": "Typography components",
5
5
  "keywords": [
6
6
  "Lit"
@@ -19,8 +19,8 @@
19
19
  "url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
20
20
  },
21
21
  "dependencies": {
22
- "@fluid-topics/ft-wc-utils": "^0.1.6",
22
+ "@fluid-topics/ft-wc-utils": "^0.1.7",
23
23
  "lit": "^2.0.2"
24
24
  },
25
- "gitHead": "c441937eb1375dc40ff477dec50b917f2adf3b38"
25
+ "gitHead": "78397cca67971191c46739cfb6c87481aaa65745"
26
26
  }