quasar-ui-example-viewer
Version:
Display Vue code examples with template, script and style parts with optional source and codepen links
94 lines (89 loc) • 2.15 kB
TypeScript
import Vue, { VueConstructor } from 'vue'
import { LooseDictionary } from './ts-helpers'
export interface ExampleViewer extends Vue {
/**
* The title for the example
*/
title : string
/**
* All examples should be put in an "examples" folder. This property is the name of the file to be displayed in that folder.
*/
file : string
/**
* The tooltip to be used for the label
*/
tooltipLabel? : string
/**
* The ribbon color
*/
ribbonColor? : string
/**
* The ribbon text color
*/
ribbonTextColor? : string
/**
* The ribbon leaf color
*/
ribbonLeafColor? : string
/**
* The url location for the example (without file name)
*/
locationUrl? : string
/**
* The icon to use for location
*/
locationIcon? : string
/**
* Does not show the codepen icon (use this for examples don't work on codepen)
*/
noEdit? : boolean
/**
* One or more paths to UMD files to be loaded into the codepen
*/
jsPaths? : StringArray
/**
* One or more CSS files to be loaded into the codepen
*/
cssPaths? : StringArray
/**
* Don't show copy-to-clipboard icon
*/
noCopy? : boolean
/**
* Icon to use for the copy-to-clipboard icon
*/
copyIcon? : string
/**
* Tooltip text to be used for copy icon
*/
copyLabel? : string
/**
* The text to be display after copy to clipboard
*/
copyResponse? : string
/**
* Don't show line numbers in source views
*/
noLineNumbers? : boolean
/**
* Don't use anchor links on title
*/
noAnchor? : boolean
/**
* Anchor copied to clipboard
*/
anchorResponse? : string
/**
* This is combined with property `title` when codepen is opened
*/
codepenTitle? : string
}
import { StringArray } from './types'
declare module 'vue/types/vue' {
interface Vue {
}
}
export * from './types'
export * from './ts-helpers'
export as namespace ExampleViewer
export const ExampleViewer: VueConstructor<ExampleViewer>