
Research
/Security News
Weaponizing Discord for Command and Control Across npm, PyPI, and RubyGems.org
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
@silexlabs/grapesjs-advanced-selector
Advanced tools
A GrapesJS plugin for managing advanced CSS selectors with a visual interface
An advanced selector management plugin for GrapesJS, designed for cases where the default Selector Manager falls short
This code is part of a larger project: about Silex v3 The Advanced Selector Manager comes pre-installed in Silex v3, give it a try here
Before: GrapesJs default Selector Manager
After:
GrapesJs Advanced Selector Manager
With body h1.btn
selected:
.child
(already possible with the default Selector Manager).child:pseudo
(already possible with the default Selector Manager).parent > .child
.parent:pseudo > .child
.parent:pseudo .child
tag .child
:nth-child(2)
:not(.child)
Choose one of the following methods:
<script src="https://unpkg.com/@silexlabs/grapesjs-advanced-selector"></script>
npm i @silexlabs/grapesjs-advanced-selector
git clone https://github.com/silexlabs/grapesjs-advanced-selector.git
Include the plugin with GrapesJS in your HTML:
<link href="https://unpkg.com/grapesjs/dist/css/grapes.min.css" rel="stylesheet">
<script src="https://unpkg.com/grapesjs"></script>
<script src="https://unpkg.com/@silexlabs/grapesjs-advanced-selector"></script>
<div id="gjs"></div>
const editor = grapesjs.init({
container: '#gjs',
height: '100%',
fromElement: true,
storageManager: false,
plugins: ['@silexlabs/grapesjs-advanced-selector'],
});
Customize the plugin’s behavior by passing options:
Option | Description | Default |
---|---|---|
i18n | Internationalization object see the files in src/i18n | The content of src/i18n/en.ts |
helpLinks | Links to help resources | {} |
helpLinks.actionBar | Link to help resources for the action bar | https://docs.silex.me/en/user/selectors |
Use the plugin with modern JavaScript imports:
import grapesjs from 'grapesjs';
import plugin from '@silexlabs/grapesjs-advanced-selector';
import 'grapesjs/dist/css/grapes.min.css';
const editor = grapesjs.init({
container: '#gjs',
plugins: [plugin],
pluginsOpts: {
[plugin]: { /* options */ }
},
});
To contribute, follow these steps:
Clone the Repository:
git clone https://github.com/silexlabs/grapesjs-advanced-selector.git
cd @silexlabs/grapesjs-advanced-selector
Install Dependencies:
npm install
Start Development Server:
npm start
Build the Plugin:
npm run build
AGPL-3.0
FAQs
A GrapesJS plugin for managing advanced CSS selectors with a visual interface
The npm package @silexlabs/grapesjs-advanced-selector receives a total of 25 weekly downloads. As such, @silexlabs/grapesjs-advanced-selector popularity was classified as not popular.
We found that @silexlabs/grapesjs-advanced-selector 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.
Research
/Security News
Socket researchers uncover how threat actors weaponize Discord across the npm, PyPI, and RubyGems ecosystems to exfiltrate sensitive data.
Security News
Socket now integrates with Bun 1.3’s Security Scanner API to block risky packages at install time and enforce your organization’s policies in local dev and CI.
Research
The Socket Threat Research Team is tracking weekly intrusions into the npm registry that follow a repeatable adversarial playbook used by North Korean state-sponsored actors.