Sha256: e4a96179bffa2c43d0cabfea7d691c2a4d1cab75432ba765bc1083fd1021d446

Contents?: true

Size: 1.08 KB

Versions: 17

Compression:

Stored size: 1.08 KB

Contents

<template>
  <div
    class="absolute bottom-0 flex justify-center w-full"
    v-if="displayInsertButton"
  >
    <router-link
      :to="{
        name: 'addSectionAfter',
        params: { sectionId: hoveredSection.sectionId },
      }"
      custom
      v-slot="{ navigate }"
    >
      <button
        type="button"
        @click="navigate"
        @keypress.enter="navigate"
        class="button top-4"
      >
        <icon name="ri-add-line" size="1.5rem" />
      </button>
    </router-link>
  </div>
</template>

<script>
export default {
  name: 'SectionHighlighterBottomActions',
  props: {
    hoveredSection: { type: Object },
  },
  computed: {
    displayInsertButton() {
      if (!this.hoveredSection) return false
      const { definition } = this.hoveredSection
      return definition.insertButton
    },
  },
}
</script>

<style scoped>
.button {
  @apply bg-editor-primary
    pointer-events-auto
    flex
    items-center
    justify-center
    h-8
    w-8
    rounded-full
    text-white
    text-opacity-75
    relative;
}

.button:hover {
  @apply text-opacity-100;
}
</style>

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
maglevcms-1.4.0 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.3.0 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.2.2 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.2.1 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.2.0 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.1.7 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.1.6 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.1.5 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.1.4 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.1.3 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.1.2 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.1.1 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.1.0 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.0.0 app/javascript/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.0.0.rc3 app/javascript/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.0.0.rc2 app/javascript/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.0.0.rc1 app/javascript/editor/components/section-highlighter/bottom-actions.vue