mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FEATURE: introduces list/compact_list components
This commit is contained in:
@@ -93,8 +93,13 @@ class ThemeSettingsManager
|
||||
(max.is_a?(::Integer) || max.is_a?(::Float)) && max != ::Float::INFINITY
|
||||
end
|
||||
|
||||
class List < self; end
|
||||
class String < self
|
||||
class List < self
|
||||
def list_type
|
||||
@opts[:list_type]
|
||||
end
|
||||
end
|
||||
|
||||
class String < self
|
||||
def is_valid_value?(new_value)
|
||||
(@opts[:min]..@opts[:max]).include? new_value.to_s.length
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user