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

@twilio-paste/types

Package Overview
Dependencies
Maintainers
5
Versions
63
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@twilio-paste/types - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

dist/style-props/background.d.ts

11

CHANGELOG.md

@@ -6,2 +6,13 @@ # Change Log

# [1.1.0](https://github.com/twilio-labs/paste/compare/@twilio-paste/types@1.0.0...@twilio-paste/types@1.1.0) (2019-10-31)
### Features
* update types package to styled-system v5 format ([#154](https://github.com/twilio-labs/paste/issues/154)) ([117c41e](https://github.com/twilio-labs/paste/commit/117c41e463b11440582e740c28cc067c06d16e67))
# 1.0.0 (2019-10-29)

@@ -8,0 +19,0 @@

59

dist/style-props/border.d.ts

@@ -0,30 +1,47 @@

import * as CSS from 'csstype';
import { ThemeShape } from '@twilio-paste/theme-tokens';
import { ResponsiveValue, BorderStyleProps } from 'styled-system';
declare type Radii = ResponsiveValue<keyof ThemeShape['radii']>;
import { ResponsiveValue } from 'styled-system';
export declare type BorderRadius = ResponsiveValue<keyof ThemeShape['radii']>;
export declare type BorderWidth = ResponsiveValue<keyof ThemeShape['borderWidths']>;
export declare type BorderColor = ResponsiveValue<keyof ThemeShape['borderColors']>;
export interface BorderRadiusProps {
borderRadius?: Radii;
borderBottomLeftRadius?: Radii;
borderBottomRightRadius?: Radii;
borderTopLeftRadius?: Radii;
borderTopRightRadius?: Radii;
borderRadius?: BorderRadius;
borderBottomLeftRadius?: BorderRadius;
borderBottomRightRadius?: BorderRadius;
borderTopLeftRadius?: BorderRadius;
borderTopRightRadius?: BorderRadius;
}
declare type BorderWidths = ResponsiveValue<keyof ThemeShape['borderWidths']>;
export interface BorderWidthProps {
borderWidth?: BorderWidths;
borderBottomWidth?: BorderWidths;
borderLeftWidth?: BorderWidths;
borderRightWidth?: BorderWidths;
borderTopWidth?: BorderWidths;
borderWidth?: BorderWidth;
borderBottomWidth?: BorderWidth;
borderLeftWidth?: BorderWidth;
borderRightWidth?: BorderWidth;
borderTopWidth?: BorderWidth;
}
declare type BorderColors = ResponsiveValue<keyof ThemeShape['borderColors']>;
export interface BorderColorProps {
borderColor?: BorderColors;
borderBottomColor?: BorderColors;
borderLeftColor?: BorderColors;
borderRightColor?: BorderColors;
borderTopColor?: BorderColors;
borderColor?: BorderColor;
borderBottomColor?: BorderColor;
borderLeftColor?: BorderColor;
borderRightColor?: BorderColor;
borderTopColor?: BorderColor;
}
export interface BorderProps extends BorderWidthProps, BorderStyleProps, BorderRadiusProps, BorderColorProps {
export declare type BorderStyle = ResponsiveValue<CSS.BorderStyleProperty>;
export declare type BorderTopStyle = ResponsiveValue<CSS.BorderTopStyleProperty>;
export declare type BorderRightStyle = ResponsiveValue<CSS.BorderRightStyleProperty>;
export declare type BorderBottomStyle = ResponsiveValue<CSS.BorderBottomStyleProperty>;
export declare type BorderLeftStyle = ResponsiveValue<CSS.BorderLeftStyleProperty>;
export interface BorderStyleProps {
borderStyle?: BorderStyle;
borderTopStyle?: BorderTopStyle;
borderRightStyle?: BorderRightStyle;
borderBottomStyle?: BorderBottomStyle;
borderLeftStyle?: BorderLeftStyle;
}
export {};
export interface BorderProps extends BorderWidthProps, BorderStyleProps, BorderColorProps, BorderRadiusProps {
border?: never;
borderTop?: never;
borderRight?: never;
borderBottom?: never;
borderLeft?: never;
}
//# sourceMappingURL=border.d.ts.map

@@ -1,8 +0,9 @@

export * from './backgroundColor';
export * from './background';
export * from './border';
export * from './boxShadow';
export * from './font';
export * from './sizing';
export * from './spacing';
export * from './zIndex';
export * from './flexbox';
export * from './layout';
export * from './position';
export * from './shadow';
export * from './space';
export * from './typography';
//# sourceMappingURL=index.d.ts.map
{
"name": "@twilio-paste/types",
"version": "1.0.0",
"version": "1.1.0",
"description": "Shared typescript typings for Paste",

@@ -42,3 +42,3 @@ "author": "Twilio Inc.",

},
"gitHead": "3f8786355696cd4d1df5281cb7f0f18cfd2b8ebe"
"gitHead": "82780d3fc81ecc80e655f08a794e4d42a2efff38"
}
# @twilio-paste/types
Typescript typings used in multiple Paste packages
## Notes
This package exports types mimicking the styled-system high level grouping here: https://styled-system.com/api. There are cases where we differ from styled-system due to our token implementation. Specifically:
- We don't have a `color` grouping. You can either:
- Use the `BackgroundColor` and `TextColor` types that are exported individually
- Use `TypographyProps` (which includes textColor) or `BackgroundProps` (which includes backgroundColor)
- The `Shadow` typing forbids `textShadow` currently, until we have tokens for those.
- The `background` and `border` shorthands are also forbidden because it makes it tough to type as tokens.

Sorry, the diff of this file is not supported yet

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