Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

yet-another-react-lightbox

Package Overview
Dependencies
Maintainers
1
Versions
133
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

yet-another-react-lightbox - npm Package Compare versions

Comparing version 1.11.1 to 1.12.0

12

dist/plugins/Captions.js
import * as React from "react";
import { cssClass, cssVar, isDefined, makeUseContext } from "../core/utils.js";
import { clsx, cssClass, cssVar, isDefined, makeUseContext } from "../core/utils.js";
import { useEvents } from "../core/contexts/Events.js";

@@ -7,3 +7,3 @@ import { createModule } from "../core/index.js";

const defaultMaxLines = 3;
const cls = (className) => cssClass(`slide_${className}`);
const cssPrefix = (className) => cssClass(`slide_${className}`);
const hasTitle = (slide) => "title" in slide ? typeof slide.title === "string" : false;

@@ -15,7 +15,7 @@ const hasDescription = (slide) => "description" in slide ? typeof slide.description === "string" : false;

const { toolbarWidth } = useCaptions();
return (React.createElement("div", { className: cls(`title_container`) },
React.createElement("div", { className: cls("title"), ...(toolbarWidth ? { style: { [cssVar("toolbar_width")]: `${toolbarWidth}px` } } : null) }, title)));
return (React.createElement("div", { className: clsx(cssPrefix("captions_container"), cssPrefix("title_container")) },
React.createElement("div", { className: cssPrefix("title"), ...(toolbarWidth ? { style: { [cssVar("toolbar_width")]: `${toolbarWidth}px` } } : null) }, title)));
};
const Description = ({ description, align, maxLines }) => (React.createElement("div", { className: cls("description_container") },
React.createElement("div", { className: cls("description"), ...(align !== defaultTextAlign || maxLines !== defaultMaxLines
const Description = ({ description, align, maxLines }) => (React.createElement("div", { className: clsx(cssPrefix("captions_container"), cssPrefix("description_container")) },
React.createElement("div", { className: cssPrefix("description"), ...(align !== defaultTextAlign || maxLines !== defaultMaxLines
? {

@@ -22,0 +22,0 @@ style: {

{
"name": "yet-another-react-lightbox",
"version": "1.11.1",
"version": "1.12.0",
"description": "Modern React lightbox component",

@@ -5,0 +5,0 @@ "author": "Igor Danchenko",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc