quasar-ui-danx 0.4.14 → 0.4.15

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "quasar-ui-danx",
3
- "version": "0.4.14",
3
+ "version": "0.4.15",
4
4
  "author": "Dan <dan@flytedesk.com>",
5
5
  "description": "DanX Vue / Quasar component library",
6
6
  "license": "MIT",
@@ -375,7 +375,7 @@ export function fMarkdownCode(type: string, string: string | object): string {
375
375
  if (typeof string === "object" || isJSON(string)) {
376
376
  switch (type) {
377
377
  case "yaml":
378
- string = stringifyYAML(string);
378
+ string = stringifyYAML(typeof string === "string" ? JSON.parse(string) : string);
379
379
  break;
380
380
  case "ts":
381
381
  string = "";
@@ -9,8 +9,8 @@ const store = new Map<string, any>();
9
9
  * Returns the stored object that should be used instead of the passed object as the returned object is shared across the system
10
10
  */
11
11
  export function storeObject<T extends TypedObject>(newObject: T): ShallowReactive<T> {
12
- const id = newObject.id || newObject.name;
13
- const type = newObject.__type;
12
+ const id = newObject?.id || newObject?.name;
13
+ const type = newObject?.__type;
14
14
  if (!id || !type) return shallowReactive(newObject);
15
15
 
16
16
  if (!newObject.__id) {