{"version":3,"sources":["webpack://@verndale/toolkit/./src/js/modules/read-more.js"],"names":["Module","Component"],"mappings":"kJAEA,MAAMA,UAAeC,WAAU,CAC7B,eAAgB,CACd,KAAK,IAAM,CACT,KAAM,KAAK,GAAG,cAAc,uCAAuC,CACrE,EAEA,KAAK,MAAQ,OAAO,WAAW,qBAAqB,EACpD,KAAK,YAAY,CACnB,CAEA,cAAe,CACb,KAAK,MAAM,iBAAiB,SAAU,IAAM,CAC1C,KAAK,YAAY,CACnB,CAAC,CACH,CAEA,aAAc,CACR,KAAK,GAAG,cAAgB,KAAO,KAAK,MAAM,SAC5C,KAAK,IAAI,KAAK,UAAU,IACtB,8CACF,EACA,KAAK,GAAG,UAAU,IAChB,0CACF,IAEA,KAAK,IAAI,KAAK,UAAU,OACtB,8CACF,EACA,KAAK,GAAG,UAAU,OAChB,0CACF,EAEJ,CACF,CAEA,UAAeD,C","file":"scripts/389.66362f45.js","sourcesContent":["import { Component } from '@verndale/core';\n\nclass Module extends Component {\n setupDefaults() {\n this.dom = {\n copy: this.el.querySelector('.featured-leadership-card__copy-inner'),\n };\n\n this.media = window.matchMedia('(max-width: 1024px)');\n this.setReadMore();\n }\n\n addListeners() {\n this.media.addEventListener('change', () => {\n this.setReadMore();\n });\n }\n\n setReadMore() {\n if (this.el.clientHeight >= 148 && this.media.matches) {\n this.dom.copy.classList.add(\n 'featured-leadership-card__copy-inner--closed'\n );\n this.el.classList.add(\n 'featured-leadership-card__copy--overflow'\n );\n } else {\n this.dom.copy.classList.remove(\n 'featured-leadership-card__copy-inner--closed'\n );\n this.el.classList.remove(\n 'featured-leadership-card__copy--overflow'\n );\n }\n }\n}\n\nexport default Module;\n"],"sourceRoot":""}