
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
@spectrum-web-components/coachmark
Advanced tools
`<sp-coachmark>` is a temporary message that educates users through new or unfamiliar product experiences. They can be chained into a sequence to form a tour.
<sp-coachmark>
is a temporary message that educates users through new or unfamiliar product experiences. They can be chained into a sequence to form a tour.
yarn add @spectrum-web-components/coachmark
Import the side effectful registration of <sp-coachmark>
via:
import '@spectrum-web-components/coachmark/sp-coachmark.js';
When looking to leverage the Coachmark
base class as a type and/or for extension purposes, do so via:
import { Coachmark } from '@spectrum-web-components/coachmark';
The coachmark consists of several key parts:
slot="title"
)slot="content"
)slot="actions"
)slot="asset"
or src
attribute)primary-cta
and secondary-cta
attributes)current-step
and total-steps
attributes)modifierKeys
and shortcutKey
properties)Here's a complete example showing the anatomy:
<sp-coachmark
current-step="2"
total-steps="8"
open
primary-cta="Next"
secondary-cta="Previous"
>
<!-- Title -->
<div slot="title">Welcome to the Tour</div>
<!-- Main content -->
<div slot="content">
This coachmark demonstrates the various parts that make up the
component.
</div>
<!-- Media content -->
<img
slot="asset"
src="https://picsum.photos/id/237/200/300"
alt="Feature demonstration"
/>
<!-- Action menu -->
<sp-action-menu
slot="actions"
label="More Actions"
placement="bottom-end"
quiet
>
<sp-menu-item>Skip tour</sp-menu-item>
<sp-menu-item>Restart tour</sp-menu-item>
</sp-action-menu>
</sp-coachmark>
The primary-cta
and secondary-cta
attributes are used to display navigation buttons.
<sp-coachmark
id="coachmark-navigation"
open
primary-cta="Next"
secondary-cta="Previous"
>
<div slot="title">Coachmark with navigation</div>
<div slot="content">
This coachmark demonstrates the navigation buttons.
</div>
<!-- Action menu -->
<sp-action-menu
slot="actions"
label="More Actions"
placement="bottom-end"
quiet
>
<sp-menu-item>Skip tour</sp-menu-item>
<sp-menu-item>Restart tour</sp-menu-item>
</sp-action-menu>
</sp-coachmark>
Progress Indicator
The current-step
and total-steps
attributes are used to display a progress indicator.
<sp-coachmark
id="coachmark-progress"
open
current-step="2"
total-steps="8"
primary-cta="Next"
secondary-cta="Previous"
>
<div slot="title">Coachmark with progress indicator</div>
<div slot="content">
This coachmark demonstrates the progress indicator.
</div>
<!-- Action menu -->
<sp-action-menu
slot="actions"
label="More Actions"
placement="bottom-end"
quiet
>
<sp-menu-item>Skip tour</sp-menu-item>
<sp-menu-item>Restart tour</sp-menu-item>
</sp-action-menu>
</sp-coachmark>
Keyboard Shortcuts
The shortcut-key
is the primary key used to trigger an interaction and are typically an alphanumeric value (and thus will be rendered as an uppercase character).
<sp-coachmark
open
current-step="2"
total-steps="8"
primary-cta="Next"
secondary-cta="Previous"
shortcut-key="⌘"
>
<div slot="title">Shortcut Key</div>
<div slot="content">This coachmark demonstrates the shortcut key.</div>
<!-- Action menu -->
<sp-action-menu
slot="actions"
label="More Actions"
placement="bottom-end"
quiet
>
<sp-menu-item>Skip tour</sp-menu-item>
<sp-menu-item>Restart tour</sp-menu-item>
</sp-action-menu>
</sp-coachmark>
Modifier Keys
The modifierKeys
is an array of modifier keys used to trigger an interaction. This is not an attribute, but a property so we need to set it via JavaScript.
<sp-coachmark
open
current-step="2"
total-steps="8"
primary-cta="Next"
secondary-cta="Previous"
id="coachmark-keys"
>
<div slot="title">Coachmark with modifier keys</div>
<div slot="content">This coachmark demonstrates the modifier keys.</div>
<!-- Action menu -->
<sp-action-menu
slot="actions"
label="More Actions"
placement="bottom-end"
quiet
>
<sp-menu-item>Skip tour</sp-menu-item>
<sp-menu-item>Restart tour</sp-menu-item>
</sp-action-menu>
</sp-coachmark>
<script type="module">
const initCoachMark = () => {
const coachmark = document.querySelector('#coachmark-keys');
const modifierKeys = ['⇧ Shift', '⌘'];
coachmark.modifierKeys = modifierKeys;
};
customElements.whenDefined('code-example').then(() => {
customElements.whenDefined('sp-coachmark').then(() => {
initCoachMark();
});
});
</script>
User action-dependent coachmarks are designed to guide users based on their interactions within your application. In such cases, there is no "Next Step" button, as the coachmark progresses when the user takes a specific action. This allows users to learn by doing, rather than simply reading instructions. The coachmark remains until the user performs the required action or takes an alternative route in the tour, such as skipping, restarting, or moving back to a previous step.
Inside the <sp-coachmark>
, add the content and instructions for the coachmark in the <sp-coachmark>
. You can also define primary and secondary CTA buttons for user interaction.
<sp-coachmark
id="coachmark-action"
open
current-step="2"
total-steps="8"
primary-cta="Asset added"
secondary-cta="Previous"
>
<div slot="title">Coachmark with user action</div>
<div slot="content">
This coachmark waits for the user to complete a specific action.
</div>
<sp-action-menu
label="More Actions"
placement="bottom-end"
quiet
slot="actions"
>
<sp-menu-item>Skip tour</sp-menu-item>
<sp-menu-item>Restart tour</sp-menu-item>
</sp-action-menu>
</sp-coachmark>
Coachmarks should be designed with accessibility in mind:
For users that rely on screen readers, coachmarks announce their presence and content appropriately. The component manages focus to ensure users can navigate through the tour using only a keyboard.
1.8.0 (2025-09-23)
sp-picker: Fixed escape key behavior in modal overlays containing picker components. Previously, pressing the Escape key when a picker was open inside a modal overlay would not properly close the modal, instead moving focus to the picker. Now, the escape key correctly closes the picker first (if open), then closes the modal overlay on subsequent escape key presses.
This fix adds a check for this.open
in the picker's handleEscape
method to ensure proper modal overlay closure behavior.
sp-overlay: Added allow-outside-click
property to <sp-overlay>
with deprecation notice. This property allows clicks outside the overlay to close it, but is not recommended for accessibility reasons and will be removed in a future version.
This property is being added as deprecated to support the fallback for showModal()
which was removed as part of performance optimization. We will no longer support outside clicks for modal overlays as they violate accessibility guidelines.
The property defaults to false
and shows deprecation warnings when used. Consider using explicit close buttons or modal/page overlay types instead for better accessibility.
sp-menu: Fixed : Fix iPad scrolling issue in picker dropdown where scrolling through menu items would accidentally select the first touched item and close the picker.
The fix implements touch gesture detection to distinguish between scrolling and selection. Added isScrolling
getter for public API access. Test on iPad devices with long menus to validate scrolling behavior and selection accuracy.
sp-overlay: Fixed : Added body scroll prevention for modal and page overlays. Overlay automatically blocks body scroll when modal or page overlays are open and restores the original scroll state when they are closed, improving user experience and accessibility for modal dialogs.
sp-clear-button: Clear button styles have been updated to the latest Spectrum CSS version of the clear button. This update includes a major reduction in the number of custom property abstractions needed to support the multiple theming layers (as seen in the styles
package).
This update spans the following additional packages:
As the updated styles now offer additional styling options, we have added the following API to the clear button component that exists in the button
package:
quiet
- when set to true, the button will be rendered as a quiet button. This is useful for cases where you want to use the clear button in a more subtle way.disabled
- when set to true, the button will be rendered as a disabled button.static-color
- currently this only supports the white
context color. This is useful for cases where the button appears on a dark background texture. This is a replacement for the previously used variant="overBackground"
attribute which is deprecated.The variant="overBackground"
attribute is deprecated; please use the new static-color="white"
attribute instead. When this property is used in the component, a deprecation warning will be shown in the console when in debug mode. The variant
attribute will be removed in a future release.
sp-card: Fixed the card component's CSS by moving block-size: 100%
from the base :host
selector to only apply to gallery
and quiet
variants
sp-overlay: Fixed : external click registration behavior in the sp-overlay
component. Programmatic clicks on elements outside of modal overlays now properly register and close the overlay, while user-initiated clicks are prevented from doing so.
sp-card: Enhanced the Card component's checkbox functionality with improved screen reader support and keyboard navigation.
sp-progress-bar: Added: Deprecation warning for the over-background attribute.
sp-combobox: Replace the use of offsetWidth with a resizeObserver to avoid unecessary, performance-impacting layout reflows.
sp-styles: Bring the CJK font alias token fix from CSS #3883 4e3a120
.
The --spectrum-cjk-font
token was incorrectly mapped to the code font-family stack instead of --spectrum-cjk-font-family-stack
. Thanks @byteakp!
sp-color-wheel: Fixed <sp-color-wheel>
step attribute functionality for keyboard navigation. The step attribute now properly controls the increment size when using arrow keys to navigate the color wheel.
sp-switch: ### Fix down state colors for switch
Because the postcss-hover-media-feature
plugin converts hover styles into a media query for devices that support hover, the hover styles were overriding any active/down state styles. We needed to target the active/down states of the switch with additional active state selectors, in order to ensure that the active state takes precedence over the hover state, maintaining the correct visual behavior of the switch component across different interaction states.
This fix should address hover + active state discrepancies in S1 and S2 foundations.
sp-contextual-help: Fixed a typo in the default info
variant label from "Informations" to "Information".
Additionally, added package dependency for @spectrum-web-components/reactive-controllers@1.7.0
.
sp-slider: Editable sliders will now reliably emit input
events when interaction starts with the track.
sp-link: Fixed quiet variant links not showing keyboard focus state in Safari. Links with the quiet
attribute now properly display focus indicators when navigating with keyboard, improving accessibility for keyboard users.
sp-progress-bar: Smooths the transition animation of indeterminate progress bar by overriding the incoming CSS, and positioning the animating fill element completely off of the progress bar track in both LTR and RTL languages. Before, the fill element was automatically starting on the track which led to a jarring animation loop.
sp-divider: Added: staticColor
property to the Divider component, enabling programmatic control of the existing static color functionality.
FAQs
`<sp-coachmark>` is a temporary message that educates users through new or unfamiliar product experiences. They can be chained into a sequence to form a tour.
The npm package @spectrum-web-components/coachmark receives a total of 2,060 weekly downloads. As such, @spectrum-web-components/coachmark popularity was classified as popular.
We found that @spectrum-web-components/coachmark demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 7 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
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.