
Security News
NVD Concedes Inability to Keep Pace with Surging CVE Disclosures in 2025
Security experts warn that recent classification changes obscure the true scope of the NVD backlog as CVE volume hits all-time highs.
widget-crm-form
Advanced tools
# submodule
git submodule init
git submodule update
bash ./npm.sh i
# run
npm run serve
npm run dev
npm run build
#lint
npm run lint
npm run lint:js
npm run list:style
npm run lintfix
npm i -D path fs-extra widget-crm-form
// webpack.config.js
const path = require('path');
const fs = require('fs-extra');
const CrmCopyPlugin = require('widget-crm-form');
module.exports = {
plugins: [
new CrmCopyPlugin(fs, {
widget: path.resolve(__dirname, 'widget'),
src: path.resolve(__dirname, 'node_modules/widget-crm-form/dist'),
dest: path.resolve(__dirname, 'widget/app')
})
]
}
import timestamp from 'widget-crm-form/dist/timestamp';
/**
* @param {string} u шлях до віджета
* @param {boolean} f при відсутності шрифт Roboto - true
* @param {object} d document
* @param {object} w window
* @param {number|string} t Time Stamp
*/
!window.WidgetApp && (function(u, f, d, w, t) {
var s=d.createElement('script');
s.async=true;
s.src=u+'crm-form.js?t='+t;
// s.src=u+'crm-form-back-office.js?t='+t; для back-office
d.head.appendChild(s);
w.onload=function(){f&&w.WidgetApp.addFonts();};
}(`/widget/app/${timestamp}/`, false, document, window, (Date.now() / 180000 | 0)));
<?php
require($_SERVER["DOCUMENT_ROOT"] . "/widget/app/widget-timestamp.php");
?>
<!-- додається на сайт одноразово -->
<script>
/**
* @param {string} u шлях до віджета
* @param {boolean} f при відсутності шрифт Roboto - true
* @param {object} d document
* @param {object} w window
* @param {number|string} t Time Stamp
*/
!window.WidgetApp && (function(u, f, d, w, t) {
var s=d.createElement('script');
s.async=true;
s.src=u+'crm-form.js?t='+t;
// s.src=u+'crm-form-back-office.js?t='+t; для back-office
d.head.appendChild(s);
w.onload=function(){f&&w.WidgetApp.addFonts();};
}('/widget/app/<?php echo $widget_timestamp; ?>/',true,document,window,(Date.now()/180000|0)));
</script>
/**
* @description Виклик форми в попапі
* @param {number} id - ідентифікатор форми
* @param {any} saved - збережені дані по полях
* @example window.WidgetApp.crmFormsPopup(561);
* @example window.WidgetApp.crmFormsPopup(561, { 'nswerList[44]': { disabled: true, value: 'sdfsdfsdf' } });
*/
window.WidgetApp.crmFormsPopup(id: number, saved?: any)
/**
* @description Виклик форм в попапі (селект)
* @param {{ id: number; name: string; }[]} items - масив елементів селекту, name - назва селекту для відображення
* @example window.WidgetApp.crmFormsPopupSelect([{"id": 560, "name": "Написати в відділ Сервіс"},{"id": 561, "name": "Написати нам повідомлення"},{"id": 562, "name": "Задати питання"}]);
*/
window.WidgetApp.crmFormsPopupSelect(items: { id: number; name: string; }[]);
/**
* @description Виклик форми в розмітці
* @param {HTMLElement} el HTMLElement
* @param {number} id ідентифікатор форми
* @example window.WidgetApp.crmFormsStatic(document.querySelector('.block'), 561);
* @example window.WidgetApp.crmFormsStatic(561, { 'nswerList[44]': { disabled: true, value: 'sdfsdfsdf' } });
*/
window.WidgetApp.crmFormsStatic(el: HTMLElement, id: number, saved?: any);
/**
* @description додавання шрифта Roboto
* @example window.WidgetApp.addFonts();
*/
window.WidgetApp.addFonts();
<!-- data-form-id (required) - ідентифікатор форми -->
<button data-form-id='560'>Написати в відділ Сервіс</button>
<button data-form-id='561'>Написати нам повідомлення</button>
<button data-form-id='562'>Задати питання</button>
<button data-form-id='562' data-form-saved='{ "nswerList[44]": { "disabled": true, "value": "sdfsdfsdf" }}'>Задати питання</button>
<!-- data-form-items (required) - Масив з назвами і ідентифікаторами форм -->
<button data-form-items='[{"id": 560, "name": "Написати в відділ Сервіс"},{"id": 561, "name": "Написати нам повідомлення"},{"id": 562, "name": "Задати питання"}]'>Тематика звернення</button>
<!-- data-form-id (required) - ідентифікатор форми -->
<!-- data-type - тип відображення -->
<div data-form-id='560' data-type='static'></div>
<div data-form-id='560' data-type='static' data-form-saved='{ "nswerList[44]": { "disabled": true, "value": "sdfsdfsdf" }}'></div>
<!-- data-reviews (required) - ідентифікатор форми -->
<!-- data-page - сторінка (product) -->
<div data-reviews='855757' data-page='product'></div>
<!-- data-wobblers (required) -->
<div data-wobblers></div>
© 2023
FAQs
widget omni channel platform & reviews
The npm package widget-crm-form receives a total of 86 weekly downloads. As such, widget-crm-form popularity was classified as not popular.
We found that widget-crm-form demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Security experts warn that recent classification changes obscure the true scope of the NVD backlog as CVE volume hits all-time highs.
Security Fundamentals
Attackers use obfuscation to hide malware in open source packages. Learn how to spot these techniques across npm, PyPI, Maven, and more.
Security News
Join Socket for exclusive networking events, rooftop gatherings, and one-on-one meetings during BSidesSF and RSA 2025 in San Francisco.