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

@dnvt/padded-grid

Package Overview
Dependencies
Maintainers
0
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@dnvt/padded-grid

A development tool for visualizing and maintaining consistent grid systems in React applications. Similar to design tools like Figma, it provides toggleable grid overlays that help ensure precise spacing, alignment, and layout consistency during developme

  • 0.1.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

Padded Grid

A development tool for visualizing and maintaining consistent grid systems in React applications. Similar to design tools like Figma, it provides toggleable grid overlays that help ensure precise spacing, alignment, and layout consistency during development.

What is it?

Padded Grid helps you:

  • Visualize column grids and baseline grids while building your layouts
  • Maintain consistent spacing and alignment across your application
  • Toggle different grid systems on/off during development
  • Ensure your designs match their specifications

↓ Demo in construction...

Grid Visualization Example

Features

  • 🎯 Interactive grid overlays for development
  • 📏 Column grid visualization (like Figma's layout grid)
  • 📐 Baseline grid for typography alignment
  • 🎚️ Toggleable grid guides
  • 📱 Responsive grid visualization
  • 🎨 Customizable grid colors and opacity
  • 🔧 TypeScript-first with comprehensive types
  • ⚡️ Zero runtime dependencies
  • 🪶 Tree-shakeable & optimized bundle

Why Use It?

When building complex layouts, it's crucial to maintain consistent spacing and alignment. While CSS Grid and Flexbox are powerful layout tools, they don't provide visual guides during development. Padded Grid bridges this gap by offering:

  1. Visual Feedback: See your grid system while you build
  2. Design Consistency: Match your implementation to design specs
  3. Typography Alignment: Ensure text follows your baseline grid
  4. Development Efficiency: Quickly spot alignment issues

Installation

# npm
npm install padded-grid

Quick Start

import { PaddedGrid, XGrid, YGrid } from 'padded-grid';
import 'padded-grid/styles.css';

function App() {
  // Toggle grid visibility during development
  const showGrid = process.env.NODE_ENV === 'development';

  return (
    <PaddedGrid config={{ maxWidth: "1200px" }}>
      {/* Column grid overlay */}
      <XGrid columns={12} gap={16} show={showGrid} />

      {/* Baseline grid for typography alignment */}
      <YGrid base={8} show={showGrid} />

      <main>Your content...</main>
    </PaddedGrid>
  );
}

The grid overlays help you visualize and maintain consistent spacing during development. See Development Usage Guide for detailed examples and best practices.

Documentation

Browser Support

  • Modern browsers (Chrome, Firefox, Safari, Edge)
  • CSS Grid Layout support required
  • No IE11 support

Contributing

See CONTRIBUTING.md for guidelines.

License

MIT © François Denavaut

Keywords

FAQs

Package last updated on 08 Dec 2024

Did you know?

Socket

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.

Install

Related posts

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