hsass-0.8.0: Integrating Sass into Haskell applications.

Safe HaskellNone
LanguageHaskell2010

Text.Sass.Functions

Contents

Description

Provides support for user-defined functions, importers and headers.

Synopsis

Functions

type SassFunctionType Source #

Arguments

 = SassValue

Arguments of the function (SassList).

-> IO SassValue

Result of the computation.

Type of the function that may be used in sass source.

data SassFunction Source #

Description of the function that may be used in sass source.

Constructors

SassFunction 

Fields

Imports and headers

data SassImport Source #

Represents a sass import - a sass content with additional metadata.

Even though this ADT has four fields, you may just provide either importPath and importAbsolutePath and leave loading to the library, or provide importSource and do not provide importAbsolutePath. Nevertheless, you are free to provide all of the fields.

Constructors

SassImport 

Fields

type SassImporterType Source #

Arguments

 = String

Path to the import that needs to be loaded.

-> String

Absolute path to the importing file.

-> IO [SassImport]

Imports.

Type of the function that acts like an importer.

You may return the empty list in order to tell libsass to handle the import by itself.

data SassImporter Source #

Description of the importer.

Constructors

SassImporter 

Fields

type SassHeaderType Source #

Arguments

 = String

Absolute path to the file being processed.

-> IO [SassImport]

Imports.

Type of the function that acts like a header.

data SassHeader Source #

Description of the header.

Constructors

SassHeader 

Fields

makeSourceImport :: String -> SassImport Source #

makeSourceImport s is equivalent to SassImport Nothing Nothing (Just s) Nothing.

makePathImport :: String -> SassImport Source #

makePathImport p is equivalent to SassImport (Just p) (Just p) Nothing Nothing.