
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.
@stejnar/tabs
Advanced tools
Angular component library for reusable tab views.
Components are agnostic but can be extended for styling or to reduce the DOM tree.
The Service allows tabs to be nested and remember the latest tab.
Build with lib-starter: https://github.com/Stejnar/lib-starter
npm package:
https://www.npmjs.com/package/@stejnar/tabs
$ npm install --save @stejnar/tabs --production
<tabs>
@Input name: string
addTab(tab: Tab): void
selectTab(tab: Tab): void
<tab>
@Input name: string
@Input title: string
registerStateProvider(name: string): BehaviorSubject
setTab(providerName: string, tabName: string, provider?: StateProvider): void
<tabs name="diet">
<tab name="fruits" title="I am a fruitarian!">
...
</tab>
<tab name="veggie" title="I am a veggie!">
...
</tab>
<tab name="meat" title="I am a meatboy!">
...
</tab>
</tabs>
@Component({
selector: 'parent-component',
template: `
<child-component></child-component>
<child-component></child-component>
`
})
export class ParentComponent extends TabsComponent {
name: string = 'custom';
constructor(tabsService: TabsService) {
super(tabsService);
}
...
}
@Component({
selector: 'child-component',
template: `
<h4>{{ title }}</h4>
<ng-content></ng-content>
`,
host: {
'[style.display]': 'active ? "block" : "none"'
}
})
export class ChildComponent extends TabComponent {
name: string = "child1";
title: string = "I am a custom component!";
constructor(tabs: ParentComponent, tabsService: TabsService) {
super(tabs, tabsService);
}
...
}
host: {
'[style.display]': 'active ? "block" : "none"'
}
This is one of multiple approaches!
You could also give it a class with ngClass directive, which
allows CSS transitions or implement @angular/animations directly into the class.
Although there is also the good ol' *ngIf directive.
Any suggestions? Contact me or collaborate!
Send an e-mail to:
a.butkereit@gmail.com
$ git clone https://github.com/Stejnar/stejnar-tabs.git
$ cd stejnar-tabs-master
$ npm install
$ npm run build:example
$ npm start
FAQs
Angular component library
We found that @stejnar/tabs demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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.