Sha256: edc1947b3fe735dd771f89c362fabc429322c7e2069e4b7650fb33b065c8e6c0

Contents?: true

Size: 1.09 KB

Versions: 8

Compression:

Stored size: 1.09 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"
      >
        <uikit-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

8 entries across 8 versions & 1 rubygems

Version Path
maglevcms-1.8.0 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.7.3 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.7.2 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.7.1 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.7.0 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.6.1 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.6.0 app/frontend/editor/components/section-highlighter/bottom-actions.vue
maglevcms-1.5.1 app/frontend/editor/components/section-highlighter/bottom-actions.vue