Skip to content

Commit 58122b2

Browse files
Add zip and index functions to Sass::Script::Functions Overview, edit function descriptions for clarity.
See issue sass#676
1 parent b063d1f commit 58122b2

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

lib/sass/script/functions.rb

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,12 @@ module Sass::Script
147147
# \{#append append($list1, $val, \[$separator\])}
148148
# : Appends a single value onto the end of a list.
149149
#
150+
# \{#zip zip($list1, $list2, ...)}
151+
# : Combines several lists into a single multidimensional list.
152+
#
153+
# \{#index index($list, $value)}
154+
# : Returns the position of a value within a list, or false.
155+
#
150156
# ## Introspection Functions
151157
#
152158
# \{#type_of type-of($value)}
@@ -1358,8 +1364,8 @@ def append(list, val, separator = Sass::Script::String.new("auto"))
13581364
declare :append, [:list, :val]
13591365
declare :append, [:list, :val, :separator]
13601366

1361-
# Combines several lists into a single comma separated list
1362-
# space separated lists.
1367+
# Combines several lists into a single comma separated list, where the nth
1368+
# value is a space separated list of the source lists' nth values.
13631369
#
13641370
# The length of the resulting list is the length of the
13651371
# shortest list.
@@ -1384,8 +1390,8 @@ def zip(*lists)
13841390
declare :zip, [], :var_args => true
13851391

13861392

1387-
# Returns the position of the given value within the given
1388-
# list. If not found, returns false.
1393+
# Returns the position of a value within a list. If not found, returns
1394+
# false.
13891395
#
13901396
# @example
13911397
# index(1px solid red, solid) => 2

0 commit comments

Comments
 (0)