Browse Source

WIP easter egg for geodata feature

pull/4723/head
flisowna 2 years ago
parent
commit
49eeedd582
  1. 0
      packages/nc-gui/components/general/EasterEgg.vue
  2. 5
      packages/nc-gui/components/smartsheet/sidebar/MenuBottom.vue
  3. 1
      packages/nc-gui/context/index.ts

0
packages/nc-gui/components/general/EasterEgg.vue

5
packages/nc-gui/components/smartsheet/sidebar/MenuBottom.vue

@ -1,6 +1,8 @@
<script lang="ts" setup> <script lang="ts" setup>
import { ViewTypes } from 'nocodb-sdk' import { ViewTypes } from 'nocodb-sdk'
import { useNuxtApp, useSmartsheetStoreOrThrow, viewIcons } from '#imports' import { IsGeodataActiveInj, ref, useNuxtApp, useSmartsheetStoreOrThrow, viewIcons } from '#imports'
const isGeodataActive = inject(IsGeodataActiveInj, ref(false))
interface Emits { interface Emits {
(event: 'openModal', data: { type: ViewTypes; title?: string }): void (event: 'openModal', data: { type: ViewTypes; title?: string }): void
@ -115,6 +117,7 @@ function onOpenModal(type: ViewTypes, title = '') {
</a-menu-item> </a-menu-item>
<a-menu-item <a-menu-item
v-if="isGeodataActive"
key="map" key="map"
class="group !flex !items-center !my-0 !h-2.5rem nc-create-map-view" class="group !flex !items-center !my-0 !h-2.5rem nc-create-map-view"
@click="onOpenModal(ViewTypes.MAP)" @click="onOpenModal(ViewTypes.MAP)"

1
packages/nc-gui/context/index.ts

@ -17,6 +17,7 @@ export const IsFormInj: InjectionKey<Ref<boolean>> = Symbol('is-form-injection')
export const IsGridInj: InjectionKey<Ref<boolean>> = Symbol('is-grid-injection') export const IsGridInj: InjectionKey<Ref<boolean>> = Symbol('is-grid-injection')
export const IsGalleryInj: InjectionKey<Ref<boolean>> = Symbol('is-gallery-injection') export const IsGalleryInj: InjectionKey<Ref<boolean>> = Symbol('is-gallery-injection')
export const IsMapInj: InjectionKey<Ref<boolean>> = Symbol('is-map-injection') export const IsMapInj: InjectionKey<Ref<boolean>> = Symbol('is-map-injection')
export const IsGeodataActiveInj: InjectionKey<Ref<boolean>> = Symbol('is-geodata-active-injection')
export const IsKanbanInj: InjectionKey<Ref<boolean>> = Symbol('is-kanban-injection') export const IsKanbanInj: InjectionKey<Ref<boolean>> = Symbol('is-kanban-injection')
export const IsLockedInj: InjectionKey<Ref<boolean>> = Symbol('is-locked-injection') export const IsLockedInj: InjectionKey<Ref<boolean>> = Symbol('is-locked-injection')
export const CellValueInj: InjectionKey<Ref<any>> = Symbol('cell-value-injection') export const CellValueInj: InjectionKey<Ref<any>> = Symbol('cell-value-injection')

Loading…
Cancel
Save