Liking cljdoc? Tell your friends :D

baredom.components.x-liquid-dock.model


attr-blurcljs

source

attr-bob-intensitycljs

source

attr-colorcljs

source

attr-disabledcljs

source

attr-gapcljs

source

attr-magnet-radiuscljs

source

attr-magnet-strengthcljs

source

attr-positioncljs

source

attr-ripple-scalecljs

source

attr-ripple-speedcljs

source

attr-thresholdcljs

source

compute-bob-tiltcljs

(compute-bob-tilt influence dx-sign position bob-intensity)

Compute icon bob (lift), tilt (rotation), and scale based on influence, cursor direction relative to the icon, dock position, and bob-intensity.

  • dx-sign: -1 if cursor is left/above, +1 if right/below (for tilt direction)
  • bob-intensity: 0 = icons don't move, 1 = normal, 2 = dramatic

Returns {:lift :rotation :scale} where lift is pixels along dock-normal, rotation is degrees, scale is a multiplier.

Compute icon bob (lift), tilt (rotation), and scale based on influence,
cursor direction relative to the icon, dock position, and bob-intensity.

- dx-sign: -1 if cursor is left/above, +1 if right/below (for tilt direction)
- bob-intensity: 0 = icons don't move, 1 = normal, 2 = dramatic

Returns {:lift :rotation :scale} where lift is pixels along dock-normal,
rotation is degrees, scale is a multiplier.
sourceraw docstring

compute-item-influencecljs

(compute-item-influence ix iy mx my magnet-radius magnet-strength active-scale)

Given an item center (ix, iy) and mouse position (mx, my), compute the influence factor [0..1] based on distance and magnet-radius. Returns a map with :influence, :scale, :tx, :ty.

  • influence: 0 when dist >= magnet-radius, 1 at dist = 0
  • scale: 1.0 + influence^2 * magnet-strength * active-scale-boost
  • tx/ty: directional offset toward the cursor
Given an item center (ix, iy) and mouse position (mx, my), compute the
influence factor [0..1] based on distance and magnet-radius. Returns a map
with :influence, :scale, :tx, :ty.

- influence: 0 when dist >= magnet-radius, 1 at dist = 0
- scale: 1.0 + influence^2 * magnet-strength * active-scale-boost
- tx/ty: directional offset toward the cursor
sourceraw docstring

compute-phantom-offsetcljs

(compute-phantom-offset influence position)

Compute phantom blob offset from rest position based on influence and dock position. The phantom rises away from the dock edge (up for bottom, down for top, etc.) and scales up to create the viscous neck effect.

Returns {:dx :dy :scale} where dx/dy are pixel offsets and scale is the phantom blob scale factor.

Compute phantom blob offset from rest position based on influence and dock
position. The phantom rises away from the dock edge (up for bottom, down for
top, etc.) and scales up to create the viscous neck effect.

Returns {:dx :dy :scale} where dx/dy are pixel offsets and scale is the
phantom blob scale factor.
sourceraw docstring

css-bgcljs

source

css-bordercljs

source

css-colorcljs

source

css-gapcljs

source

css-glow-colorcljs

source

css-item-active-scalecljs

source

css-item-sizecljs

source

css-paddingcljs

source

css-radiuscljs

source

css-shadowcljs

source

css-z-indexcljs

source

event-schemacljs

source

event-selectcljs

source

lerpcljs

(lerp current target speed)

Linear interpolation: moves current toward target by speed fraction.

Linear interpolation: moves current toward target by speed fraction.
sourceraw docstring

normalizecljs

(normalize {:keys [position-raw gap-raw blur-raw threshold-raw ripple-scale-raw
                   ripple-speed-raw color-raw magnet-radius-raw
                   magnet-strength-raw bob-intensity-raw disabled-attr]})

Normalise raw attribute inputs into a stable view-model map.

Input keys: :position-raw string | nil :gap-raw string | nil :blur-raw string | nil :threshold-raw string | nil :ripple-scale-raw string | nil :ripple-speed-raw string | nil :color-raw string | nil :magnet-radius-raw string | nil :magnet-strength-raw string | nil :bob-intensity-raw string | nil :disabled-attr string | nil (presence-based boolean)

Output keys: :position string :gap number :blur number :threshold string :ripple-scale number :ripple-speed number :color string :magnet-radius number :magnet-strength number :bob-intensity number :disabled? boolean :vertical? boolean

Normalise raw attribute inputs into a stable view-model map.

Input keys:
  :position-raw        string | nil
  :gap-raw             string | nil
  :blur-raw            string | nil
  :threshold-raw       string | nil
  :ripple-scale-raw    string | nil
  :ripple-speed-raw    string | nil
  :color-raw           string | nil
  :magnet-radius-raw   string | nil
  :magnet-strength-raw string | nil
  :bob-intensity-raw   string | nil
  :disabled-attr       string | nil  (presence-based boolean)

Output keys:
  :position        string
  :gap             number
  :blur            number
  :threshold       string
  :ripple-scale    number
  :ripple-speed    number
  :color           string
  :magnet-radius   number
  :magnet-strength number
  :bob-intensity   number
  :disabled?       boolean
  :vertical?       boolean
sourceraw docstring

observed-attributescljs

source

parse-blurcljs

(parse-blur s)
source

parse-bob-intensitycljs

(parse-bob-intensity s)
source

parse-bool-attrcljs

(parse-bool-attr s)

Boolean from attribute presence: nil → false, any string → true.

Boolean from attribute presence: nil → false, any string → true.
sourceraw docstring

parse-colorcljs

(parse-color s)

Parse color attribute. Any non-empty string passes through.

Parse color attribute. Any non-empty string passes through.
sourceraw docstring

parse-float-clampedcljs

(parse-float-clamped s default-val lo hi)

Parse a string to a float clamped in [lo, hi]. Returns default-val on failure.

Parse a string to a float clamped in [lo, hi]. Returns default-val on failure.
sourceraw docstring

parse-gapcljs

(parse-gap s)
source

parse-magnet-radiuscljs

(parse-magnet-radius s)
source

parse-magnet-strengthcljs

(parse-magnet-strength s)
source

parse-positioncljs

(parse-position s)

Parse position attribute to one of bottom/top/left/right. Default bottom.

Parse position attribute to one of bottom/top/left/right. Default bottom.
sourceraw docstring

parse-ripple-scalecljs

(parse-ripple-scale s)
source

parse-ripple-speedcljs

(parse-ripple-speed s)
source

parse-thresholdcljs

(parse-threshold s)

Parse threshold to a color-matrix values string.

Parse threshold to a color-matrix values string.
sourceraw docstring

property-apicljs

source

select-detailcljs

(select-detail index item source)

Build event detail map for x-liquid-dock-select.

Build event detail map for x-liquid-dock-select.
sourceraw docstring

tag-namecljs

source

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close