System.register(["./p-0935a593.system.js","./p-ee65aef1.system.js"],(function(i){"use strict";var e,t,a,s,o,n,r;return{setters:[function(i){e=i.r;t=i.c;a=i.h;s=i.H;o=i.g},function(i){n=i.e;r=i.d}],execute:function(){var l=":host{--border-head-cell-default:var(--pine-border-width-thin) solid var(--pine-color-grey-300);--box-shadow-default:3px 3px 6px -2px rgba(0, 0, 0, 0.1);--color-background-fixed:var(--pine-color-white);--color-sorting:var(--pine-color-charcoal-500);--color-text-default:var(--pine-color-charcoal-200);--dimension-fixed-cell-position:0;--font-size-head-cell:var(--pine-font-size-087);--font-weight-cell-default:var(--pine-font-weight-normal);--line-height-cell-default:var(--pine-line-height-125);--padding-cell-default:calc(var(--pine-spacing-300) / 2);--spacing-margin-inline-start-arrow:var(--pine-spacing-050);--spacing-padding-arrow:calc(var(--pine-spacing-050) / 2);--spacing-padding-block-compact:var(--pine-spacing-050);-webkit-border-after:var(--border-head-cell-default);border-block-end:var(--border-head-cell-default);color:var(--color-text-default);display:table-cell;font-size:var(--font-size-head-cell);font-style:normal;font-weight:var(--font-weight-cell-default);line-height:var(--line-height-cell-default);padding:var(--padding-cell-default);text-align:start;vertical-align:inherit}:host(.is-compact){padding-block:var(--spacing-padding-block-compact)}:host(.is-fixed){background:var(--color-background-fixed);left:var(--dimension-fixed-cell-position);position:-webkit-sticky;position:sticky;z-index:1}:host(.has-scrolled.is-fixed){-webkit-box-shadow:var(--box-shadow-default);box-shadow:var(--box-shadow-default)}:host(.is-sortable){cursor:pointer}:host(.is-sortable) pds-icon{-webkit-margin-start:var(--spacing-margin-inline-start-arrow);margin-inline-start:var(--spacing-margin-inline-start-arrow);-webkit-padding-before:var(--spacing-padding-arrow);padding-block-start:var(--spacing-padding-arrow);position:absolute}:host(.is-sortable:hover),:host(.is-active){color:var(--color-sorting)}";var c=l;var d=i("pds_table_head_cell",function(){function i(i){var a=this;e(this,i);this.pdsTableSort=t(this,"pdsTableSort",7);this.handleScroll=function(){if(a.tableRef.scrollLeft>0){a.tableScrolling=true}else{a.tableScrolling=false}};this.toggleSort=function(){if(a.sortable){var i=a.hostElement.innerText.trim();a.sortingDirection=a.sortingDirection==="asc"?"desc":"asc";a.tableRef.querySelectorAll("pds-table-head-cell").forEach((function(i){i.classList.remove("is-active")}));a.hostElement.classList.toggle("is-active");a.pdsTableSort.emit({column:i,direction:a.sortingDirection})}};this.sortable=undefined;this.sortingDirection="asc";this.tableScrolling=false;this.isSelected=false}i.prototype.componentWillRender=function(){this.tableRef=this.hostElement.closest("pds-table")};i.prototype.componentDidLoad=function(){if(this.tableRef&&this.tableRef.responsive&&this.tableRef.fixedColumn){this.tableRef.addEventListener("scroll",this.handleScroll)}};i.prototype.classNames=function(){var i=[];if(this.tableRef&&this.tableRef.compact){i.push("is-compact")}if(this.sortable){i.push("is-sortable")}if(this.sortable&&this.sortingDirection!==null){i.push("sort-"+this.sortingDirection)}if(this.tableRef&&this.tableRef.fixedColumn&&this.tableScrolling){i.push("has-scrolled")}return i.join("  ")};i.prototype.render=function(){return a(s,{key:"72e242a22774d4b534b7a8653673606e0e9c6ef1",class:this.classNames(),role:"columnheader",onClick:this.toggleSort,style:this.tableRef&&this.tableRef.fixedColumn&&this.tableRef.selectable?{"--fixed-cell-position":"40px"}:{}},a("slot",{key:"08e1d5aab1761ed097e2669716884196c946bcc3"}),this.sortable&&a("pds-icon",{key:"43421a2b1401426878601468acee702ce45404bf",icon:this.sortingDirection==="asc"?n:r}))};Object.defineProperty(i.prototype,"hostElement",{get:function(){return o(this)},enumerable:false,configurable:true});return i}());d.style=c}}}));
//# sourceMappingURL=p-807d5d68.system.entry.js.map