@contentful/f36-drag-handle
Advanced tools
Comparing version 4.0.1-next-v4-6443.2247 to 4.0.1-next-v4-6465.2248
@@ -1,2 +0,2 @@ | ||
import e from"@babel/runtime/helpers/esm/extends";import{cx as o,css as r}from"emotion";import t,{useCallback as a,forwardRef as s,useState as i}from"react";import{usePrimitive as n}from"@contentful/f36-core";import{DragIcon as d}from"@contentful/f36-icons";import l from"@contentful/f36-tokens";var c,u,m,b;c={},u="DragHandle",m=()=>f,Object.defineProperty(c,u,{get:m,set:b,enumerable:!0,configurable:!0});const f=s((({className:s,isActive:c,isFocused:u,isHovered:m,label:b,onBlur:f,onFocus:g,onMouseEnter:p,onMouseLeave:v,testId:h="cf-ui-drag-handle",...x},E)=>{const y={label:r({name:"1b512s9",styles:"position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0;"}),root:({isActive:e,isFocused:t,isHovered:a})=>o(r({alignItems:"center",backgroundColor:l.gray100,border:0,borderBottomLeftRadius:l.borderRadiusMedium,borderRight:`1px solid ${l.gray300}`,borderTopLeftRadius:l.borderRadiusMedium,boxSizing:"border-box",display:"flex",justifyContent:"center",padding:0,position:"relative",transition:`background-color ${l.transitionDurationDefault} ${l.transitionEasingDefault}`,width:l.spacingL,"&:hover, &:focus":{backgroundColor:l.colorElementLight}},""),(e||t||a)&&r({backgroundColor:l.gray200,cursor:e?"grabbing":"grab"},""))},{primitiveProps:k,Element:D}=n(x),[L,M]=i(u),[R,C]=i(m),F=a((e=>{M(!0),g&&g(e)}),[g]),H=a((e=>{M(!1),f&&f(e)}),[f]),w=a((e=>{C(!0),p&&p(e)}),[p]),I=a((e=>{C(!1),v&&v(e)}),[v]);return t.createElement(D,e({as:"button"},k,{className:o(y.root({isActive:c,isFocused:L,isHovered:R}),s),onBlur:H,onFocus:F,onMouseEnter:w,onMouseLeave:I,testId:h,ref:E}),t.createElement(d,{variant:"muted"}),t.createElement("span",{className:y.label},b))}));export{f as DragHandle}; | ||
import e from"@babel/runtime/helpers/esm/extends";import{cx as o,css as r}from"emotion";import t,{useCallback as a,useState as s,forwardRef as i}from"react";import{usePrimitive as n}from"@contentful/f36-core";import{DragIcon as d}from"@contentful/f36-icons";import l from"@contentful/f36-tokens";var c,u,m,b;c={},u="DragHandle",m=()=>f,Object.defineProperty(c,u,{get:m,set:b,enumerable:!0,configurable:!0});const f=i((({className:i,isActive:c,isFocused:u,isHovered:m,label:b,onBlur:f,onFocus:g,onMouseEnter:p,onMouseLeave:v,testId:h="cf-ui-drag-handle",...x},E)=>{const y={label:r({name:"1b512s9",styles:"position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0;"}),root:({isActive:e,isFocused:t,isHovered:a})=>o(r({alignItems:"center",backgroundColor:l.gray100,border:0,borderBottomLeftRadius:l.borderRadiusMedium,borderRight:`1px solid ${l.gray300}`,borderTopLeftRadius:l.borderRadiusMedium,boxSizing:"border-box",display:"flex",justifyContent:"center",padding:0,position:"relative",transition:`background-color ${l.transitionDurationDefault} ${l.transitionEasingDefault}`,width:l.spacingL,"&:hover, &:focus":{backgroundColor:l.colorElementLight}},""),(e||t||a)&&r({backgroundColor:l.gray200,cursor:e?"grabbing":"grab"},""))},{primitiveProps:k,Element:D}=n(x),[L,M]=s(u),[R,C]=s(m),F=a((e=>{M(!0),g&&g(e)}),[g]),H=a((e=>{M(!1),f&&f(e)}),[f]),w=a((e=>{C(!0),p&&p(e)}),[p]),I=a((e=>{C(!1),v&&v(e)}),[v]);return t.createElement(D,e({as:"button"},k,{className:o(y.root({isActive:c,isFocused:L,isHovered:R}),i),onBlur:H,onFocus:F,onMouseEnter:w,onMouseLeave:I,testId:h,ref:E}),t.createElement(d,{variant:"muted"}),t.createElement("span",{className:y.label},b))}));export{f as DragHandle}; | ||
//# sourceMappingURL=module.js.map |
{ | ||
"name": "@contentful/f36-drag-handle", | ||
"version": "4.0.1-next-v4-6443.2247+236460ce", | ||
"version": "4.0.1-next-v4-6465.2248+74ededc0", | ||
"description": "Forma 36: DragHandle component", | ||
@@ -10,5 +10,5 @@ "scripts": { | ||
"@babel/runtime": "^7.6.2", | ||
"@contentful/f36-core": "4.0.1-next-v4-6443.2247+236460ce", | ||
"@contentful/f36-icons": "4.0.1-next-v4-6443.2247+236460ce", | ||
"@contentful/f36-tokens": "4.0.1-next-v4-6443.2247+236460ce", | ||
"@contentful/f36-core": "4.0.1-next-v4-6465.2248+74ededc0", | ||
"@contentful/f36-icons": "4.0.1-next-v4-6465.2248+74ededc0", | ||
"@contentful/f36-tokens": "4.0.1-next-v4-6465.2248+74ededc0", | ||
"emotion": "^10.0.17" | ||
@@ -37,3 +37,3 @@ }, | ||
}, | ||
"gitHead": "236460ce04c14e69f1711a49589bb92a96134272" | ||
"gitHead": "74ededc0207fac1c34cc8128a9b63e502f2a8301" | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package