New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@q42/q-cms-components

Package Overview
Dependencies
Maintainers
16
Versions
112
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@q42/q-cms-components - npm Package Compare versions

Comparing version 10.2.2 to 10.3.0

15

package.json
{
"name": "@q42/q-cms-components",
"version": "10.2.2",
"version": "10.3.0",
"description": "Front-end package that provides a UI on top of the QMS back-end.",

@@ -25,8 +25,9 @@ "keywords": [

"dependencies": {
"@tiptap/extension-image": "^2.0.3",
"@tiptap/extension-link": "^2.0.3",
"@tiptap/extension-underline": "^2.0.3",
"@tiptap/pm": "^2.0.3",
"@tiptap/starter-kit": "^2.0.3",
"@tiptap/vue-2": "^2.0.3",
"@tiptap/extension-image": "^2.1.6",
"@tiptap/extension-link": "^2.1.6",
"@tiptap/extension-placeholder": "^2.1.6",
"@tiptap/extension-underline": "^2.1.6",
"@tiptap/pm": "^2.1.6",
"@tiptap/starter-kit": "^2.1.6",
"@tiptap/vue-2": "^2.1.6",
"autosize": "5.0.x",

@@ -33,0 +34,0 @@ "bootstrap": "4.6.x",

@@ -76,10 +76,13 @@ import CrudHelpers from '../crud/crud-helpers';

export function getComponentTitle(store, component, schemaProperties) {
// 1. first look if there is a property with isDisplayTitle
for (const propName in schemaProperties) {
const propSchema = schemaProperties[propName];
// 1. first look if there is a property with isDisplayTitle
if (propSchema.isDisplayTitle) {
return component[propName];
}
}
for (const propName in schemaProperties) {
const propSchema = schemaProperties[propName];
// 2. secondly check if the component is of type 'RichTextBlock', return friendly title instead of rich text content.

@@ -86,0 +89,0 @@ if (component.$type === 'Q.Cms.SampleCms.Domain.Components.Content.RichTextBlock, Q.Cms.SampleCms.Domain') {

/* global describe, it, expect */
import { initialValue } from './schema-scripts';
import { getComponentTitle, initialValue } from './schema-scripts';

@@ -242,1 +242,47 @@ describe('intialValue', function () {

});
describe('getComponentTitle', function () {
it('should get a display title when it is present', function () {
const store = {};
const component = {
$type: 'Q.Cms.SampleCms.Domain.Items.OpeningPeriod, Q.Cms.SampleCms.Domain',
bar: 'bar displaytitle',
foo: 'foo title'
};
const schemaProperties = {
foo: {
type: 'string',
isDisplayTitle: false
},
bar: {
type: 'string',
isDisplayTitle: true
}
};
const title = getComponentTitle(store, component, schemaProperties);
expect(title).toEqual('bar displaytitle');
});
it('should get a display title when it is rich text', function () {
const store = {};
const component = {
$type: 'Q.Cms.SampleCms.Domain.Components.Content.RichTextBlock, Q.Cms.SampleCms.Domain',
bar: 'bar displaytitle',
foo: 'foo title'
};
const schemaProperties = {
foo: {
type: 'string',
isDisplayTitle: false
},
bar: {
type: 'string',
isDisplayTitle: false
}
};
const title = getComponentTitle(store, component, schemaProperties);
expect(title).toEqual('Rich text');
});
});

@@ -174,3 +174,7 @@ import { ActionTree, GetterTree, MutationTree } from 'vuex';

async fetchItems({ state, commit }, payload: SearchCrudItemPayload = state.searchState) {
commit('isLoading', true);
// To prevent the relation picker from triggering a reload of the current crud item page due to a change in isLoading, loading must be disabled. This situation occurs when the relation picker loads a crud item of the same type as the one currently displayed on the page.
if (!payload.disableLoading) {
commit('isLoading', true);
}
try {

@@ -189,3 +193,5 @@ const result = await CrudApi.search(state.path, payload.query, payload.languageFilter, payload.page, payload.sort);

} finally {
commit('isLoading', false);
if (!payload.disableLoading) {
commit('isLoading', false);
}
}

@@ -192,0 +198,0 @@ },

@@ -318,2 +318,3 @@ import type { CrudStoreItemsModel } from '../stores/types/CrudStoreModel';

sort?: string;
disableLoading?: boolean;
}

@@ -320,0 +321,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc