File

src/utils/colorTranslator.ts

Description

Copyright (C) Mobilize.Net info@mobilize.net - All Rights Reserved

This file is part of the Mobilize Frameworks, which is proprietary and confidential.

NOTICE: All information contained herein is, and remains the property of Mobilize.Net Corporation. The intellectual and technical concepts contained herein are proprietary to Mobilize.Net Corporation and may be covered by U.S. Patents, and are protected by trade secret or copyright law. Dissemination of this information or reproduction of this material is strictly forbidden unless prior written permission is obtained from Mobilize.Net Corporation.

Index

Methods

Methods

Private Static groupEachTwo
groupEachTwo(hex: string)

It takes a string of hexadecimal characters and returns an array of strings, each of which is a pair of hexadecimal characters.

Parameters :
Name Type Optional Description
hex string No
  • The hex string.
Returns : string[]

An array of strings.

Private Static sliceHex
sliceHex(hex: string)

It takes a hex string and returns the last 6 characters of it.

Parameters :
Name Type Optional Description
hex string No
  • The hexadecimal color code.
Returns : string

The last 6 characters of the hex string.

Static toOle
toOle(hex: string)

It takes a hex color string and returns it as OLE color.

Parameters :
Name Type Optional Description
hex string No
  • string - The hex color to convert to OLE.
Returns : number | null

The hex value is being returned as a number.

Private Static validateHexColor
validateHexColor(colorHex: string)

It returns true if the string is a valid hex color, otherwise it returns false.

Parameters :
Name Type Optional Description
colorHex string No
  • The hex color string to validate.
Returns : boolean

A boolean value.

results matching ""

    No results matching ""