
        <script setup>
        import { computed } from "vue"
        import { Example, PropsTable, PageTitle } from "@viteplay/vue"
        import { useRoute, useRouter } from "vue-router"
            
        let componentProps = {"CCardHeader":[]}
        let route = useRoute()
        let router = useRouter()
        let focusId = computed(() => route.query.focus && route.hash.slice(1))
        let shouldRender = (slug) => {
          return !route.query.focus || slug === focusId.value
        }
        let hiddenCount = computed(() => {
          return ["basic","secondary"].filter((slug) => !shouldRender(slug)).length
        })

        let showAll = () => {
          router.push({ query: {}, hash: route.hash })
        }

        let openInEditor = (file) => {
           fetch('/__open-in-editor?file=' + encodeURIComponent(file))
        }
        let examples = [
          {
                title: "Basic",
                slug: "basic",
                docs: {"content":"","attrs":{}},
                // encodeURI because the example will contain html tags
                // which will cause this component to be incorrectly parsed
                code: decodeURI("%3Cscript%20setup%3E%0Aimport%20CCardHeader%20from%20'../CCardHeader.vue'%0A%3C/script%3E%0A%0A%3Ctemplate%3E%0A%20%20%3CCCardHeader%0A%20%20%20%20p_Title=%22%E3%82%BF%E3%82%A4%E3%83%88%E3%83%AB%E3%81%8C%E5%85%A5%E3%82%8A%E3%81%BE%E3%81%99%22%0A%20%20%20%20p_TitleAlign=%22center%22%0A%20%20%20%20p_Type=%22primary%22%0A%20%20%20%20:p_ButtonHidden=%22false%22%0A%20%20%20%20:p_ArrowOpen=%22true%22%0A%20%20%20%20class=%22_c_card_basic%22%0A%20%20/%3E%0A%3C/template%3E%0A%3Cstyle%3E%0A:root%20%7B%0A%20%20--q-primary:%20#5e421d;%0A%7D%0A._c_card_basic%20%7B%0A%20%20height:%2080px;%0A%20%20font-size:%2040px;%0A%7D%0A%3C/style%3E"),
                iframeUrl: "/__iframe/CCardHeader-basic.html",
                openInEditor: import.meta.env.DEV 
                  ? () => openInEditor("/Users/nakashimakeiju/ghq/github.com/CodeLic/console/src/components/CCardHeader/examples/Basic.vue") 
                  : undefined 
              },{
                title: "secondary",
                slug: "secondary",
                docs: {"content":"","attrs":{}},
                // encodeURI because the example will contain html tags
                // which will cause this component to be incorrectly parsed
                code: decodeURI("%3Cscript%20setup%3E%0Aimport%20CCardHeader%20from%20'../CCardHeader.vue'%0A%3C/script%3E%0A%0A%3Ctemplate%3E%0A%20%20%3CCCardHeader%0A%20%20%20%20p_Title=%22%E3%82%BF%E3%82%A4%E3%83%88%E3%83%AB%E3%81%8C%E5%85%A5%E3%82%8A%E3%81%BE%E3%81%99%22%0A%20%20%20%20p_TitleAlign=%22center%22%0A%20%20%20%20p_Type=%22secondary%22%0A%20%20%20%20:p_ButtonHidden=%22false%22%0A%20%20%20%20:p_ArrowOpen=%22true%22%0A%20%20%20%20class=%22_c_card_basic_second%22%0A%20%20/%3E%0A%3C/template%3E%0A%3Cstyle%3E%0A:root%20%7B%0A%20%20--q-secondary:%20#0000a0;%0A%7D%0A._c_card_basic_second%20%7B%0A%20%20height:%2030px;%0A%20%20font-size:%2024px;%0A%7D%0A%3C/style%3E"),
                iframeUrl: "/__iframe/CCardHeader-secondary.html",
                openInEditor: import.meta.env.DEV 
                  ? () => openInEditor("/Users/nakashimakeiju/ghq/github.com/CodeLic/console/src/components/CCardHeader/examples/secondary.vue") 
                  : undefined 
              }
        ]
        </script>
        <template>
          <PageTitle title="CCardHeader" :openInEditor="() => openInEditor('/Users/nakashimakeiju/ghq/github.com/CodeLic/console/src/components/CCardHeader/CCardHeader.vue')" />
          <div v-if="hiddenCount > 0" class="hidden-examples-info">
            {{ hiddenCount }} example{{ hiddenCount > 1 ? "s" : null }} hidden, <a class="viteplay-link" type="button" @click.prevent="showAll">show all</a>
          </div>
          <PropsTable componentName="CCardHeader" :componentProps="componentProps" />
          <template  
            v-for="example in examples" 
            :key="example.slug">
            <Example 
              v-if="shouldRender(example.slug)"
              :example="example" 
              :componentProps="componentProps" />
          </template>
        </template>

<style scoped>
.hidden-examples-info {
  margin: 20px 0;
}
</style>
      