compony 0.5.9 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/Gemfile.lock +1 -1
- data/README.md +21 -0
- data/VERSION +1 -1
- data/compony.gemspec +3 -3
- data/config/locales/de.yml +13 -0
- data/config/locales/en.yml +13 -0
- data/config/locales/fr.yml +14 -1
- data/doc/ComponentGenerator.html +16 -4
- data/doc/Components.html +3 -3
- data/doc/ComponentsGenerator.html +3 -3
- data/doc/Compony/Component.html +4 -4
- data/doc/Compony/ComponentMixins/Default/Labelling.html +3 -3
- data/doc/Compony/ComponentMixins/Default/Standalone/ResourcefulVerbDsl.html +3 -3
- data/doc/Compony/ComponentMixins/Default/Standalone/StandaloneDsl.html +3 -3
- data/doc/Compony/ComponentMixins/Default/Standalone/VerbDsl.html +3 -3
- data/doc/Compony/ComponentMixins/Default/Standalone.html +3 -3
- data/doc/Compony/ComponentMixins/Default.html +3 -3
- data/doc/Compony/ComponentMixins/Resourceful.html +4 -4
- data/doc/Compony/ComponentMixins.html +3 -3
- data/doc/Compony/Components/Button.html +3 -3
- data/doc/Compony/Components/Destroy.html +3 -3
- data/doc/Compony/Components/Edit.html +3 -3
- data/doc/Compony/Components/Form.html +3 -3
- data/doc/Compony/Components/Index.html +172 -0
- data/doc/Compony/Components/List.html +2731 -0
- data/doc/Compony/Components/New.html +3 -3
- data/doc/Compony/Components/Show.html +740 -0
- data/doc/Compony/Components/WithForm.html +3 -3
- data/doc/Compony/Components.html +5 -5
- data/doc/Compony/ControllerMixin.html +3 -3
- data/doc/Compony/Engine.html +3 -3
- data/doc/Compony/MethodAccessibleHash.html +3 -3
- data/doc/Compony/ModelFields/Anchormodel.html +136 -4
- data/doc/Compony/ModelFields/Association.html +4 -4
- data/doc/Compony/ModelFields/Attachment.html +4 -4
- data/doc/Compony/ModelFields/Base.html +143 -13
- data/doc/Compony/ModelFields/Boolean.html +136 -4
- data/doc/Compony/ModelFields/Color.html +4 -4
- data/doc/Compony/ModelFields/Currency.html +4 -4
- data/doc/Compony/ModelFields/Date.html +4 -4
- data/doc/Compony/ModelFields/Datetime.html +4 -4
- data/doc/Compony/ModelFields/Decimal.html +4 -4
- data/doc/Compony/ModelFields/Email.html +4 -4
- data/doc/Compony/ModelFields/Float.html +4 -4
- data/doc/Compony/ModelFields/Integer.html +83 -5
- data/doc/Compony/ModelFields/Percentage.html +4 -4
- data/doc/Compony/ModelFields/Phone.html +4 -4
- data/doc/Compony/ModelFields/RichText.html +4 -4
- data/doc/Compony/ModelFields/String.html +4 -4
- data/doc/Compony/ModelFields/Text.html +4 -4
- data/doc/Compony/ModelFields/Time.html +4 -4
- data/doc/Compony/ModelFields/Url.html +4 -4
- data/doc/Compony/ModelFields.html +3 -3
- data/doc/Compony/ModelMixin.html +26 -26
- data/doc/Compony/NaturalOrdering.html +3 -3
- data/doc/Compony/RequestContext.html +3 -3
- data/doc/Compony/Version.html +3 -3
- data/doc/Compony/ViewHelpers.html +3 -3
- data/doc/Compony.html +4 -4
- data/doc/ComponyController.html +3 -3
- data/doc/_index.html +25 -4
- data/doc/class_list.html +3 -6
- data/doc/css/full_list.css +3 -3
- data/doc/css/style.css +0 -6
- data/doc/file.README.html +37 -10
- data/doc/file_list.html +2 -5
- data/doc/frames.html +5 -10
- data/doc/index.html +37 -10
- data/doc/js/app.js +264 -294
- data/doc/js/full_list.js +4 -30
- data/doc/method_list.html +423 -114
- data/doc/top-level-namespace.html +3 -3
- data/lib/compony/components/index.rb +33 -0
- data/lib/compony/components/list.rb +418 -0
- data/lib/compony/components/show.rb +116 -0
- data/lib/compony/model_fields/anchormodel.rb +13 -0
- data/lib/compony/model_fields/base.rb +12 -0
- data/lib/compony/model_fields/boolean.rb +13 -0
- data/lib/compony/model_fields/integer.rb +3 -0
- data/lib/compony/model_mixin.rb +5 -0
- data/lib/compony.rb +3 -0
- data/lib/generators/component/component_generator.rb +6 -0
- data/lib/generators/component/templates/index.rb.erb +2 -0
- data/lib/generators/component/templates/list.rb.erb +7 -0
- data/lib/generators/component/templates/show.rb.erb +2 -0
- metadata +10 -1
data/doc/js/full_list.js
CHANGED
@@ -62,25 +62,8 @@ function enableToggles() {
|
|
62
62
|
evt.stopPropagation();
|
63
63
|
evt.preventDefault();
|
64
64
|
$(this).parent().parent().toggleClass('collapsed');
|
65
|
-
$(this).attr('aria-expanded', function (i, attr) {
|
66
|
-
return attr == 'true' ? 'false' : 'true'
|
67
|
-
});
|
68
65
|
highlight();
|
69
66
|
});
|
70
|
-
|
71
|
-
// navigation of nested classes using keyboard
|
72
|
-
$('#full_list a.toggle').on('keypress',function(evt) {
|
73
|
-
// enter key is pressed
|
74
|
-
if (evt.which == 13) {
|
75
|
-
evt.stopPropagation();
|
76
|
-
evt.preventDefault();
|
77
|
-
$(this).parent().parent().toggleClass('collapsed');
|
78
|
-
$(this).attr('aria-expanded', function (i, attr) {
|
79
|
-
return attr == 'true' ? 'false' : 'true'
|
80
|
-
});
|
81
|
-
highlight();
|
82
|
-
}
|
83
|
-
});
|
84
67
|
}
|
85
68
|
|
86
69
|
function populateSearchCache() {
|
@@ -108,7 +91,7 @@ function enableSearch() {
|
|
108
91
|
}
|
109
92
|
});
|
110
93
|
|
111
|
-
$('#full_list').after("<div id='noresults'
|
94
|
+
$('#full_list').after("<div id='noresults' style='display:none'></div>");
|
112
95
|
}
|
113
96
|
|
114
97
|
function ignoredKeyPress(event) {
|
@@ -171,14 +154,11 @@ function partialSearch(searchString, offset) {
|
|
171
154
|
function searchDone() {
|
172
155
|
searchTimeout = null;
|
173
156
|
highlight();
|
174
|
-
|
175
|
-
|
176
|
-
$('#noresults').text('No results were found.');
|
157
|
+
if ($('#full_list li:visible').size() === 0) {
|
158
|
+
$('#noresults').text('No results were found.').hide().fadeIn();
|
177
159
|
} else {
|
178
|
-
|
179
|
-
$('#noresults').text('There are ' + found + ' results.');
|
160
|
+
$('#noresults').text('').hide();
|
180
161
|
}
|
181
|
-
$('#noresults').show();
|
182
162
|
$('#content').removeClass('insearch');
|
183
163
|
}
|
184
164
|
|
@@ -208,12 +188,6 @@ function expandTo(path) {
|
|
208
188
|
$target.addClass('clicked');
|
209
189
|
$target.removeClass('collapsed');
|
210
190
|
$target.parentsUntil('#full_list', 'li').removeClass('collapsed');
|
211
|
-
|
212
|
-
$target.find('a.toggle').attr('aria-expanded', 'true')
|
213
|
-
$target.parentsUntil('#full_list', 'li').each(function(i, el) {
|
214
|
-
$(el).find('> div > a.toggle').attr('aria-expanded', 'true');
|
215
|
-
});
|
216
|
-
|
217
191
|
if($target[0]) {
|
218
192
|
window.scrollTo(window.scrollX, $target.offset().top - 250);
|
219
193
|
highlight();
|