@gedit/utils
Advanced tools
Comparing version 0.2.7 to 0.2.8
import { CacheManager, Disposable } from '../common'; | ||
export declare type CSSStyle = { | ||
export type CSSStyle = { | ||
[P in keyof CSSStyleDeclaration]?: string | number | undefined; | ||
@@ -4,0 +4,0 @@ }; |
@@ -24,3 +24,3 @@ import { Disposable } from './disposable'; | ||
} | ||
export declare type Cache<T> = { | ||
export type Cache<T> = { | ||
[P in keyof T]: T[P]; | ||
@@ -27,0 +27,0 @@ } & { |
@@ -1,2 +0,2 @@ | ||
declare type Func<T extends any[], R> = (...a: T) => R; | ||
type Func<T extends any[], R> = (...a: T) => R; | ||
/** | ||
@@ -3,0 +3,0 @@ * Composes single-argument functions from right to left. The rightmost |
@@ -24,3 +24,3 @@ /******************************************************************************** | ||
} | ||
export declare type Bindable = interfaces.Bind | interfaces.Container; | ||
export type Bindable = interfaces.Bind | interfaces.Container; | ||
export declare namespace Bindable { | ||
@@ -27,0 +27,0 @@ function isContainer(arg: Bindable): arg is interfaces.Container; |
@@ -1,3 +0,3 @@ | ||
export declare type LocalId = number; | ||
export type LocalId = number; | ||
export declare function generateLocalId(): LocalId; | ||
//# sourceMappingURL=id.d.ts.map |
@@ -1,3 +0,3 @@ | ||
export declare type Log = (message: any, ...params: any[]) => void; | ||
export declare type Loggable = (log: Log) => void; | ||
export type Log = (message: any, ...params: any[]) => void; | ||
export type Loggable = (log: Log) => void; | ||
export declare const Logger: unique symbol; | ||
@@ -4,0 +4,0 @@ export interface Logger { |
import { SchemaDecoration } from './schema'; | ||
import { PositionSchema, SizeSchema } from './schema-transform'; | ||
export declare type OpacitySchema = number; | ||
export type OpacitySchema = number; | ||
export interface FlipSchema { | ||
@@ -5,0 +5,0 @@ x: boolean; |
@@ -6,6 +6,8 @@ import { SchemaDecoration } from './schema'; | ||
} | ||
export declare type RotationSchema = number; | ||
export type RotationSchema = number; | ||
export interface OriginSchema { | ||
x: number; | ||
y: number; | ||
initX?: number; | ||
initY?: number; | ||
} | ||
@@ -12,0 +14,0 @@ export interface ScaleSchema { |
@@ -81,3 +81,3 @@ "use strict"; | ||
}, | ||
origin: { x: obj.origin.x, y: obj.origin.y }, | ||
origin: { x: obj.origin.x, y: obj.origin.y, initX: obj.origin.initX, initY: obj.origin.initY }, | ||
scale: { x: obj.scale.x, y: obj.scale.y }, | ||
@@ -99,6 +99,3 @@ skew: { x: obj.skew.x, y: obj.skew.y }, | ||
}, | ||
origin: { | ||
x: newTransform.origin.x - oldTransform.origin.x, | ||
y: newTransform.origin.y - oldTransform.origin.y, | ||
}, | ||
origin: Object.assign(Object.assign({}, newTransform.origin), { x: newTransform.origin.x - oldTransform.origin.x, y: newTransform.origin.y - oldTransform.origin.y }), | ||
scale: { | ||
@@ -128,6 +125,3 @@ x: newTransform.scale.x - oldTransform.scale.x, | ||
}, | ||
origin: { | ||
x: toFixed(newTransformDelta.origin.x + oldTransform.origin.x), | ||
y: toFixed(newTransformDelta.origin.y + oldTransform.origin.y), | ||
}, | ||
origin: Object.assign(Object.assign({}, newTransformDelta.origin), { x: toFixed(newTransformDelta.origin.x + oldTransform.origin.x), y: toFixed(newTransformDelta.origin.y + oldTransform.origin.y) }), | ||
scale: { | ||
@@ -134,0 +128,0 @@ x: toFixed(newTransformDelta.scale.x + oldTransform.scale.x), |
@@ -1,2 +0,2 @@ | ||
export declare type SchemaType = 'string' | 'integer' | 'float' | 'boolean' | 'enum' | 'object' | 'range' | 'color' | 'array'; | ||
export type SchemaType = 'string' | 'integer' | 'float' | 'boolean' | 'enum' | 'object' | 'range' | 'color' | 'array'; | ||
interface SchemaMixinDefaults { | ||
@@ -3,0 +3,0 @@ [defaultKey: string]: any; |
@@ -16,10 +16,10 @@ /******************************************************************************** | ||
********************************************************************************/ | ||
export declare type Mutable<T> = { | ||
export type Mutable<T> = { | ||
-readonly [P in keyof T]: T[P]; | ||
}; | ||
export declare type RecursivePartial<T> = { | ||
export type RecursivePartial<T> = { | ||
[P in keyof T]?: T[P] extends Array<infer I> ? Array<RecursivePartial<I>> : RecursivePartial<T[P]>; | ||
}; | ||
export declare type MaybeArray<T> = T | T[]; | ||
export declare type MaybePromise<T> = T | PromiseLike<T>; | ||
export type MaybeArray<T> = T | T[]; | ||
export type MaybePromise<T> = T | PromiseLike<T>; | ||
export interface Prioritizeable<T> { | ||
@@ -26,0 +26,0 @@ readonly priority: number; |
{ | ||
"name": "@gedit/utils", | ||
"version": "0.2.7", | ||
"version": "0.2.8", | ||
"license": "MIT", | ||
@@ -32,3 +32,3 @@ "main": "lib/common/index", | ||
}, | ||
"gitHead": "5fd2e0b75c7fa4c5972e56d59dd00d7fce84f11a" | ||
"gitHead": "0d2ac4eadcab052623caaedf2b658065129b2129" | ||
} |
@@ -12,3 +12,5 @@ import { Schema, SchemaDecoration } from './schema'; | ||
x: number, | ||
y: number | ||
y: number; | ||
initX?: number; | ||
initY?: number; | ||
} | ||
@@ -124,3 +126,3 @@ | ||
}, | ||
origin: {x: obj.origin.x, y: obj.origin.y}, | ||
origin: {x: obj.origin.x, y: obj.origin.y, initX: obj.origin.initX, initY: obj.origin.initY}, | ||
scale: {x: obj.scale.x, y: obj.scale.y}, | ||
@@ -142,2 +144,3 @@ skew: {x: obj.skew.x, y: obj.skew.y}, | ||
origin: { | ||
...newTransform.origin, | ||
x: newTransform.origin.x - oldTransform.origin.x, | ||
@@ -171,2 +174,3 @@ y: newTransform.origin.y - oldTransform.origin.y, | ||
origin: { | ||
...newTransformDelta.origin, | ||
x: toFixed(newTransformDelta.origin.x + oldTransform.origin.x), | ||
@@ -173,0 +177,0 @@ y: toFixed(newTransformDelta.origin.y + oldTransform.origin.y), |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 2 instances 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
Unidentified License
License(Experimental) Something that seems like a license was found, but its contents could not be matched with a known license.
Found 2 instances in 1 package
501662