Skip to content

Commit

Permalink
build: version 3.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
meteorlxy committed Apr 11, 2022
1 parent db0b69d commit d9b8910
Show file tree
Hide file tree
Showing 9 changed files with 99 additions and 41 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
# [3.2.0](https://github.com/meteorlxy/vue-showdown/compare/v3.1.0...v3.2.0) (2022-04-11)


### Features

* bump to showdown v2 ([5e727f8](https://github.com/meteorlxy/vue-showdown/commit/5e727f8634da2f2d7bd809591bcfbfbe4a7ab7d1))



# [3.1.0](https://github.com/meteorlxy/vue-showdown/compare/v3.0.0...v3.1.0) (2021-04-26)


Expand Down
14 changes: 6 additions & 8 deletions dist/vue-showdown.cjs.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/*!
* vue-showdown - Use showdown as a vue component
*
* @version v3.1.0
* @version v3.2.0
* @link https://vue-showdown.js.org
* @license MIT
* @copyright 2018-2021 meteorlxy
* @copyright 2018-2022 meteorlxy
*/

'use strict';
Expand All @@ -23,14 +23,12 @@ function _interopNamespace(e) {
var d = Object.getOwnPropertyDescriptor(e, k);
Object.defineProperty(n, k, d.get ? d : {
enumerable: true,
get: function () {
return e[k];
}
get: function () { return e[k]; }
});
}
});
}
n['default'] = e;
n["default"] = e;
return Object.freeze(n);
}

Expand Down Expand Up @@ -147,7 +145,7 @@ const VueShowdown = vue.defineComponent({
return props.markdown;
}
// from default slot
const slot = (_a = slots.default) === null || _a === void 0 ? void 0 : _a.call(slots)[0];
const slot = (_a = slots['default']) === null || _a === void 0 ? void 0 : _a.call(slots)[0];
if ((slot === null || slot === void 0 ? void 0 : slot.type) === vue.Text) {
return slot.children;
}
Expand Down Expand Up @@ -200,4 +198,4 @@ const VueShowdownPlugin = {
exports.showdown = showdown__namespace;
exports.VueShowdown = VueShowdown;
exports.VueShowdownPlugin = VueShowdownPlugin;
exports.default = VueShowdownPlugin;
exports["default"] = VueShowdownPlugin;
76 changes: 65 additions & 11 deletions dist/vue-showdown.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -91,15 +91,70 @@ declare const VueShowdown: vue.DefineComponent<{
};
}, () => vue.VNode<vue.RendererNode, vue.RendererElement, {
[key: string]: any;
}>, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, Record<string, any>, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<{
extensions: Required<(string | (() => showdown.ShowdownExtension | showdown.ShowdownExtension[]) | showdown.ShowdownExtension | showdown.ShowdownExtension[])[] | null | undefined>;
markdown: string | null;
tag: string;
flavor: showdown.Flavor | null;
options: showdown.ShowdownOptions;
vueTemplate: boolean;
vueTemplateData: Record<string, any>;
} & {}>, {
}>, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, Record<string, any>, string, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps, Readonly<vue.ExtractPropTypes<{
/**
* Raw markdown content
*/
markdown: {
type: PropType<string | null>;
required: false;
default: null;
};
/**
* HTML tag of the markdown wrapper
*/
tag: {
type: PropType<string>;
required: false;
default: string;
};
/**
* Showdown flavor
*
* @see https://github.com/showdownjs/showdown#flavors
*/
flavor: {
type: PropType<showdown.Flavor | null>;
required: false;
default: null;
};
/**
* Showdown options
*
* @see https://github.com/showdownjs/showdown#valid-options
*/
options: {
type: PropType<showdown.ShowdownOptions>;
required: false;
default: () => {};
};
/**
* Showdown extensions
*
* @see https://github.com/showdownjs/showdown#extensions
*/
extensions: {
type: PropType<Required<(string | (() => showdown.ShowdownExtension | showdown.ShowdownExtension[]) | showdown.ShowdownExtension | showdown.ShowdownExtension[])[] | null | undefined>>;
required: false;
default: null;
};
/**
* Treat the HTML string as Vue template. Require full build of Vue (runtime + complier)
*/
vueTemplate: {
type: BooleanConstructor;
required: false;
default: boolean;
};
/**
* Define data which is available in the Vue template. Require `vueTemplate` to be enabled
*/
vueTemplateData: {
type: ObjectConstructor;
required: false;
default: () => {};
};
}>>, {
extensions: Required<(string | (() => showdown.ShowdownExtension | showdown.ShowdownExtension[]) | showdown.ShowdownExtension | showdown.ShowdownExtension[])[] | null | undefined>;
markdown: string | null;
tag: string;
Expand All @@ -125,5 +180,4 @@ declare const VueShowdown: vue.DefineComponent<{
*/
declare const VueShowdownPlugin: Plugin;

export default VueShowdownPlugin;
export { VueShowdown, VueShowdownPlugin };
export { VueShowdown, VueShowdownPlugin, VueShowdownPlugin as default };
9 changes: 4 additions & 5 deletions dist/vue-showdown.esm.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/*!
* vue-showdown - Use showdown as a vue component
*
* @version v3.1.0
* @version v3.2.0
* @link https://vue-showdown.js.org
* @license MIT
* @copyright 2018-2021 meteorlxy
* @copyright 2018-2022 meteorlxy
*/

import * as showdown from 'showdown';
Expand Down Expand Up @@ -122,7 +122,7 @@ const VueShowdown = defineComponent({
return props.markdown;
}
// from default slot
const slot = (_a = slots.default) === null || _a === void 0 ? void 0 : _a.call(slots)[0];
const slot = (_a = slots['default']) === null || _a === void 0 ? void 0 : _a.call(slots)[0];
if ((slot === null || slot === void 0 ? void 0 : slot.type) === Text) {
return slot.children;
}
Expand Down Expand Up @@ -172,5 +172,4 @@ const VueShowdownPlugin = {
},
};

export default VueShowdownPlugin;
export { VueShowdown, VueShowdownPlugin };
export { VueShowdown, VueShowdownPlugin, VueShowdownPlugin as default };
6 changes: 3 additions & 3 deletions dist/vue-showdown.esm.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 7 additions & 9 deletions dist/vue-showdown.js
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
/*!
* vue-showdown - Use showdown as a vue component
*
* @version v3.1.0
* @version v3.2.0
* @link https://vue-showdown.js.org
* @license MIT
* @copyright 2018-2021 meteorlxy
* @copyright 2018-2022 meteorlxy
*/

(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('showdown'), require('vue')) :
typeof define === 'function' && define.amd ? define(['exports', 'showdown', 'vue'], factory) :
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.VueShowdown = {}, global.showdown, global.Vue));
}(this, (function (exports, showdown, vue) { 'use strict';
})(this, (function (exports, showdown, vue) { 'use strict';

function _interopNamespace(e) {
if (e && e.__esModule) return e;
Expand All @@ -22,14 +22,12 @@
var d = Object.getOwnPropertyDescriptor(e, k);
Object.defineProperty(n, k, d.get ? d : {
enumerable: true,
get: function () {
return e[k];
}
get: function () { return e[k]; }
});
}
});
}
n['default'] = e;
n["default"] = e;
return Object.freeze(n);
}

Expand Down Expand Up @@ -146,7 +144,7 @@
return props.markdown;
}
// from default slot
const slot = (_a = slots.default) === null || _a === void 0 ? void 0 : _a.call(slots)[0];
const slot = (_a = slots['default']) === null || _a === void 0 ? void 0 : _a.call(slots)[0];
if ((slot === null || slot === void 0 ? void 0 : slot.type) === vue.Text) {
return slot.children;
}
Expand Down Expand Up @@ -207,4 +205,4 @@

Object.defineProperty(exports, '__esModule', { value: true });

})));
}));
4 changes: 2 additions & 2 deletions dist/vue-showdown.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vue-showdown",
"version": "3.1.0",
"version": "3.2.0",
"description": "Use showdown as a vue component",
"keywords": [
"vue",
Expand Down

0 comments on commit d9b8910

Please sign in to comment.