JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 420
  • Score
    100M100P100Q103263F
  • License MIT

The latest iPhone and Pixel frames provided as Web Components

Package Exports

  • @sneas/telephone
  • @sneas/telephone/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@sneas/telephone) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

@sneas/telephone - Web Component

version

Wrap any HTML/CSS/JS code with the

<iphone-16-max></iphone-16-max> or

<pixel-9-pro></pixel-9-pro>

and it will be rendered inside an SVG mobile phone frame.

Example

Demo: https://sneas.github.io/telephone

Real world example: https://vocably.pro

Installation

<script
  defer
  src="https://cdn.jsdelivr.net/npm/@sneas/telephone@1/iphone-16-max.js"
></script>
<script
  defer
  src="https://cdn.jsdelivr.net/npm/@sneas/telephone@1/pixel-9-pro.js"
></script>

<iphone-16-max mode="light">
  iPhone content goes here.
  Set the mode="light" for the dark text in the status bar.
</iphone-16-max>

<pixel-9-pro mode="dark">
  Pixel content goes here.
  Set mode="dark" for the white text in the status bar.
</pixel-9-pro>