{"version":3,"file":"fieldFilterContainer.js","sources":["../../../Framework/Controls/fieldFilterContainer.ts"],"sourcesContent":["// Copyright by the Spark Development Network\r\n//\r\n// Licensed under the Rock Community License (the \"License\");\r\n// you may not use this file except in compliance with the License.\r\n// You may obtain a copy of the License at\r\n//\r\n// http://www.rockrms.com/license\r\n//\r\n// Unless required by applicable law or agreed to in writing, software\r\n// distributed under the License is distributed on an \"AS IS\" BASIS,\r\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n// See the License for the specific language governing permissions and\r\n// limitations under the License.\r\n// \r\n//\r\n\r\nimport { computed } from \"vue\";\r\nimport { defineComponent, PropType } from \"vue\";\r\n\r\nexport default defineComponent({\r\n name: \"FieldFilterContainer\",\r\n\r\n props: {\r\n compareLabel: {\r\n type: String as PropType\r\n },\r\n },\r\n\r\n setup(props, ctx) {\r\n /** True if the compare column should be displayed. */\r\n const hasCompareColumn = computed((): boolean => !!ctx.slots.compare || !!props.compareLabel);\r\n\r\n /** True if we have a plain text label to display in the compare column. */\r\n const hasCompareLabel = computed((): boolean => !!props.compareLabel);\r\n\r\n /** The CSS class to use for the compare column width. */\r\n const compareColumnClass = computed((): string => {\r\n if (ctx.slots.compare) {\r\n return \"col-xs-12 col-md-4\";\r\n }\r\n else if (props.compareLabel) {\r\n return \"col-xs-12 col-md-2\";\r\n }\r\n else {\r\n return \"\";\r\n }\r\n });\r\n\r\n /** The CSS class to use for the value column width. */\r\n const valueColumnClass = computed((): string => {\r\n if (ctx.slots.compare) {\r\n return \"col-xs-12 col-md-8\";\r\n }\r\n else if (props.compareLabel) {\r\n return \"col-xs-12 col-md-10\";\r\n }\r\n else {\r\n return \"col-xs-12 col-md-12\";\r\n }\r\n });\r\n\r\n return {\r\n compareColumnClass,\r\n hasCompareColumn,\r\n hasCompareLabel,\r\n valueColumnClass\r\n };\r\n },\r\n\r\n template: `\r\n
\r\n
\r\n {{ compareLabel }}\r\n \r\n
\r\n\r\n
\r\n \r\n
\r\n
\r\n`\r\n});\r\n"],"names":["defineComponent","name","props","compareLabel","type","String","setup","ctx","hasCompareColumn","computed","slots","compare","hasCompareLabel","compareColumnClass","valueColumnClass","template"],"mappings":";;;;;;;;;;AAmBA,0DAAeA,eAAe,CAAC;YAC3BC,EAAAA,IAAI,EAAE,sBAAsB;YAE5BC,EAAAA,KAAK,EAAE;YACHC,IAAAA,YAAY,EAAE;YACVC,MAAAA,IAAI,EAAEC,MAAAA;YACV,KAAA;eACH;YAEDC,EAAAA,KAAKA,CAACJ,KAAK,EAAEK,GAAG,EAAE;YAEd,IAAA,IAAMC,gBAAgB,GAAGC,QAAQ,CAAC,MAAe,CAAC,CAACF,GAAG,CAACG,KAAK,CAACC,OAAO,IAAI,CAAC,CAACT,KAAK,CAACC,YAAY,CAAC,CAAA;gBAG7F,IAAMS,eAAe,GAAGH,QAAQ,CAAC,MAAe,CAAC,CAACP,KAAK,CAACC,YAAY,CAAC,CAAA;YAGrE,IAAA,IAAMU,kBAAkB,GAAGJ,QAAQ,CAAC,MAAc;YAC9C,MAAA,IAAIF,GAAG,CAACG,KAAK,CAACC,OAAO,EAAE;YACnB,QAAA,OAAO,oBAAoB,CAAA;YAC/B,OAAC,MACI,IAAIT,KAAK,CAACC,YAAY,EAAE;YACzB,QAAA,OAAO,oBAAoB,CAAA;YAC/B,OAAC,MACI;YACD,QAAA,OAAO,EAAE,CAAA;YACb,OAAA;YACJ,KAAC,CAAC,CAAA;YAGF,IAAA,IAAMW,gBAAgB,GAAGL,QAAQ,CAAC,MAAc;YAC5C,MAAA,IAAIF,GAAG,CAACG,KAAK,CAACC,OAAO,EAAE;YACnB,QAAA,OAAO,oBAAoB,CAAA;YAC/B,OAAC,MACI,IAAIT,KAAK,CAACC,YAAY,EAAE;YACzB,QAAA,OAAO,qBAAqB,CAAA;YAChC,OAAC,MACI;YACD,QAAA,OAAO,qBAAqB,CAAA;YAChC,OAAA;YACJ,KAAC,CAAC,CAAA;gBAEF,OAAO;kBACHU,kBAAkB;kBAClBL,gBAAgB;kBAChBI,eAAe;YACfE,MAAAA,gBAAAA;iBACH,CAAA;eACJ;cAEDC,QAAQ,EAAA,4VAAA;YAYZ,CAAC,EAAC;;;;;;;;"}