iqvoc 3.2.3
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.
- data/Gemfile +69 -0
- data/Gemfile.lock +134 -0
- data/LICENSE +13 -0
- data/README.md +68 -0
- data/Rakefile +23 -0
- data/app/controllers/application_controller.rb +125 -0
- data/app/controllers/collections/hierarchical_controller.rb +44 -0
- data/app/controllers/collections_controller.rb +124 -0
- data/app/controllers/concepts/alphabetical_controller.rb +39 -0
- data/app/controllers/concepts/hierarchical_controller.rb +74 -0
- data/app/controllers/concepts/untranslated_controller.rb +38 -0
- data/app/controllers/concepts/versions_controller.rb +119 -0
- data/app/controllers/concepts_controller.rb +174 -0
- data/app/controllers/dashboard_controller.rb +43 -0
- data/app/controllers/pages_controller.rb +22 -0
- data/app/controllers/rdf_controller.rb +43 -0
- data/app/controllers/search_results_controller.rb +101 -0
- data/app/controllers/triple_store_syncs_controller.rb +45 -0
- data/app/controllers/user_sessions_controller.rb +48 -0
- data/app/controllers/users_controller.rb +81 -0
- data/app/helpers/application_helper.rb +60 -0
- data/app/helpers/concepts_helper.rb +86 -0
- data/app/helpers/dashboard_helper.rb +46 -0
- data/app/helpers/rdf_helper.rb +63 -0
- data/app/helpers/search_results_helper.rb +32 -0
- data/app/models/collection/base.rb +161 -0
- data/app/models/collection/member/base.rb +23 -0
- data/app/models/collection/member/collection.rb +33 -0
- data/app/models/collection/member/concept.rb +33 -0
- data/app/models/collection/unordered.rb +18 -0
- data/app/models/concept/base.rb +418 -0
- data/app/models/concept/relation/base.rb +95 -0
- data/app/models/concept/relation/reverse_relation_extension.rb +49 -0
- data/app/models/concept/relation/skos/base.rb +37 -0
- data/app/models/concept/relation/skos/broader/base.rb +41 -0
- data/app/models/concept/relation/skos/broader/mono.rb +28 -0
- data/app/models/concept/relation/skos/broader/poly.rb +23 -0
- data/app/models/concept/relation/skos/narrower/base.rb +37 -0
- data/app/models/concept/relation/skos/related.rb +21 -0
- data/app/models/concept/skos/base.rb +28 -0
- data/app/models/label/base.rb +98 -0
- data/app/models/label/skos/base.rb +27 -0
- data/app/models/labeling/base.rb +81 -0
- data/app/models/labeling/skos/alt_label.rb +21 -0
- data/app/models/labeling/skos/base.rb +99 -0
- data/app/models/labeling/skos/hidden_label.rb +25 -0
- data/app/models/labeling/skos/pref_label.rb +30 -0
- data/app/models/match/base.rb +57 -0
- data/app/models/match/skos/base.rb +23 -0
- data/app/models/match/skos/broad_match.rb +21 -0
- data/app/models/match/skos/close_match.rb +21 -0
- data/app/models/match/skos/exact_match.rb +21 -0
- data/app/models/match/skos/mapping_relation.rb +21 -0
- data/app/models/match/skos/narrow_match.rb +21 -0
- data/app/models/match/skos/related_match.rb +21 -0
- data/app/models/note/annotated/base.rb +29 -0
- data/app/models/note/base.rb +127 -0
- data/app/models/note/skos/base.rb +52 -0
- data/app/models/note/skos/change_note.rb +38 -0
- data/app/models/note/skos/definition.rb +33 -0
- data/app/models/note/skos/editorial_note.rb +21 -0
- data/app/models/note/skos/example.rb +21 -0
- data/app/models/note/skos/history_note.rb +21 -0
- data/app/models/note/skos/scope_note.rb +21 -0
- data/app/models/origin_mapping.rb +58 -0
- data/app/models/rdf_store.rb +96 -0
- data/app/models/search_extension.rb +58 -0
- data/app/models/user.rb +49 -0
- data/app/models/user_session.rb +23 -0
- data/app/views/collections/_collection.html.erb +10 -0
- data/app/views/collections/_form.html.erb +47 -0
- data/app/views/collections/edit.html.erb +11 -0
- data/app/views/collections/index.html.erb +12 -0
- data/app/views/collections/new.html.erb +7 -0
- data/app/views/collections/show.html.erb +53 -0
- data/app/views/collections/show.iqrdf +22 -0
- data/app/views/concepts/_base_data.html.erb +72 -0
- data/app/views/concepts/_close_match.html.erb +16 -0
- data/app/views/concepts/_show_head.html.erb +23 -0
- data/app/views/concepts/_visualization.html.erb +9 -0
- data/app/views/concepts/alphabetical/_pref_labeling.html.erb +6 -0
- data/app/views/concepts/alphabetical/index.html.erb +17 -0
- data/app/views/concepts/edit.html.erb +32 -0
- data/app/views/concepts/hierarchical/_treeview.html.erb +20 -0
- data/app/views/concepts/hierarchical/index.html.erb +5 -0
- data/app/views/concepts/index.iqrdf +24 -0
- data/app/views/concepts/new.html.erb +3 -0
- data/app/views/concepts/show_published.html.erb +16 -0
- data/app/views/concepts/show_unpublished.html.erb +43 -0
- data/app/views/concepts/untranslated/index.html.erb +23 -0
- data/app/views/dashboard/index.html.erb +47 -0
- data/app/views/errors/access_denied.html.erb +3 -0
- data/app/views/errors/multiple_choices.html.erb +11 -0
- data/app/views/errors/not_found.html.erb +8 -0
- data/app/views/kaminari/_page.html.erb +6 -0
- data/app/views/kaminari/_paginator.html.erb +15 -0
- data/app/views/layouts/_controls.html.erb +37 -0
- data/app/views/layouts/_header.html.erb +1 -0
- data/app/views/layouts/_navigation.html.erb +27 -0
- data/app/views/layouts/_sections.html.erb +8 -0
- data/app/views/layouts/application.html.erb +83 -0
- data/app/views/pages/about.html.erb +77 -0
- data/app/views/partials/_rdf_logo.html.erb +4 -0
- data/app/views/partials/collection/_member.html.erb +14 -0
- data/app/views/partials/collection_label/_search_result.html.erb +5 -0
- data/app/views/partials/concept/_edit_link_base.html.erb +4 -0
- data/app/views/partials/concept/_inline_base.html.erb +4 -0
- data/app/views/partials/concept/_new_link_base.html.erb +4 -0
- data/app/views/partials/concept/relation/_base.html.erb +8 -0
- data/app/views/partials/concept/relation/_edit_base.html.erb +15 -0
- data/app/views/partials/concept/relation/skos/_narrower.html.erb +12 -0
- data/app/views/partials/concept/relation/skos/broader/_mono.html.erb +28 -0
- data/app/views/partials/concept/relation/skos/broader/_poly.html.erb +14 -0
- data/app/views/partials/labeling/skos/_base.html.erb +17 -0
- data/app/views/partials/labeling/skos/_edit_base.html.erb +7 -0
- data/app/views/partials/labeling/skos/_search_result.html.erb +12 -0
- data/app/views/partials/match/_base.html.erb +13 -0
- data/app/views/partials/match/_edit_base.html.erb +6 -0
- data/app/views/partials/note/_base.html.erb +15 -0
- data/app/views/partials/note/_edit_base.html.erb +28 -0
- data/app/views/partials/note/_note.html.erb +14 -0
- data/app/views/partials/note/_search_result.html.erb +8 -0
- data/app/views/partials/note/skos/_edit_change_note.html.erb +47 -0
- data/app/views/partials/note/skos/definition/_search_result.html.erb +8 -0
- data/app/views/rdf/show_concept.iqrdf +5 -0
- data/app/views/search_results/_head_contents.html.erb +4 -0
- data/app/views/search_results/_rdf_links.html.erb +4 -0
- data/app/views/search_results/index.html.erb +92 -0
- data/app/views/search_results/index.iqrdf +33 -0
- data/app/views/triple_store_syncs/new.html.erb +7 -0
- data/app/views/user_sessions/new.html.erb +11 -0
- data/app/views/users/_form.html.erb +45 -0
- data/app/views/users/_user_preference.html.erb +12 -0
- data/app/views/users/edit.html.erb +14 -0
- data/app/views/users/index.html.erb +29 -0
- data/app/views/users/new.html.erb +13 -0
- data/config/application.rb +82 -0
- data/config/boot.rb +29 -0
- data/config/database.template.yml +43 -0
- data/config/database.yml +40 -0
- data/config/deploy/common.rb +79 -0
- data/config/deploy/ec2.rb +43 -0
- data/config/deploy/history.rb +29 -0
- data/config/deploy/innoq.rb +37 -0
- data/config/deploy.rb +72 -0
- data/config/engine.rb +25 -0
- data/config/environment.rb +21 -0
- data/config/environments/development.rb +74 -0
- data/config/environments/production.rb +65 -0
- data/config/environments/production.template.rb +65 -0
- data/config/environments/production_internal.rb +65 -0
- data/config/environments/test.rb +51 -0
- data/config/initializers/action_view.rb +23 -0
- data/config/initializers/active_record.rb +18 -0
- data/config/initializers/backtrace_silencers.rb +23 -0
- data/config/initializers/inflections.rb +26 -0
- data/config/initializers/iqvoc.rb +50 -0
- data/config/initializers/jdbc.rb +23 -0
- data/config/initializers/kaminari_config.rb +8 -0
- data/config/initializers/language.rb +6 -0
- data/config/initializers/mime_types.rb +24 -0
- data/config/initializers/secret_token.rb +29 -0
- data/config/initializers/secret_token.rb.template +29 -0
- data/config/initializers/session_store.rb +24 -0
- data/config/locales/activerecord.de.yml +135 -0
- data/config/locales/activerecord.en.yml +135 -0
- data/config/locales/authlogic.de.yml +38 -0
- data/config/locales/authlogic.en.yml +38 -0
- data/config/locales/de.yml +326 -0
- data/config/locales/defaults.de.yml +153 -0
- data/config/locales/en.yml +332 -0
- data/config/routes.rb +53 -0
- data/config/warble.rb +158 -0
- data/db/iqvoc_test.sqlite3 +0 -0
- data/db/migrate/20100927101502_create_schema.rb +174 -0
- data/db/migrate/20101125141218_add_collection_tables.rb +32 -0
- data/db/migrate/20101129161528_add_type_to_collections.rb +24 -0
- data/db/migrate/20101202094602_add_origin_to_collections.rb +25 -0
- data/db/migrate/20101202135420_rename_collection_contents_to_collection_members.rb +25 -0
- data/db/migrate/20101208103531_add_type_to_collection_contents.rb +27 -0
- data/db/migrate/20101210153916_add_indexes_to_collections.rb +25 -0
- data/db/migrate/20110204121244_create_collection_labels.rb +32 -0
- data/db/migrate/20110208084250_change_origin_lengths.rb +27 -0
- data/db/migrate/20110328124300_discard_collection_specifics.rb +27 -0
- data/db/migrate/20110408120357_remove_classifications_and_classifiers.rb +32 -0
- data/db/migrate/20110408120740_remove_xl_specfic_stuff.rb +39 -0
- data/db/migrate/20110420133640_change_value_in_notes.rb +8 -0
- data/db/migrate/20110427120534_add_published_at_to_labels.rb +9 -0
- data/db/migrate/20110510162719_use_mono_hierarchy_instead_of_poly_hierarchy.rb +13 -0
- data/db/migrate/20110512132624_extend_notes_value_field_length.rb +8 -0
- data/db/migrate/20110525103100_separate_note_annotation_predicates.rb +38 -0
- data/db/migrate/20110615134040_change_umt_note_annotations_to_dct.rb +9 -0
- data/db/schema.rb +127 -0
- data/db/seeds.rb +37 -0
- data/iqvoc.gemspec +27 -0
- data/lib/engine_tasks/assets.rake +49 -0
- data/lib/engine_tasks/db.rake +18 -0
- data/lib/engine_tasks/release.rake +118 -0
- data/lib/iqvoc/ability.rb +44 -0
- data/lib/iqvoc/data_helper.rb +27 -0
- data/lib/iqvoc/deep_cloning.rb +92 -0
- data/lib/iqvoc/rdf_helper.rb +67 -0
- data/lib/iqvoc/skos_importer.rb +144 -0
- data/lib/iqvoc/version.rb +19 -0
- data/lib/iqvoc/versioning.rb +151 -0
- data/lib/iqvoc.rb +228 -0
- data/lib/maker.rb +144 -0
- data/lib/ojdbc14.jar +0 -0
- data/lib/string.rb +23 -0
- data/lib/tasks/importer.rake +16 -0
- data/lib/tasks/jdbc.rake +24 -0
- data/public/404.html +26 -0
- data/public/422.html +26 -0
- data/public/500.html +26 -0
- data/public/favicon.ico +0 -0
- data/public/images/iqvoc/add.png +0 -0
- data/public/images/iqvoc/arrow_down.gif +0 -0
- data/public/images/iqvoc/arrow_up.gif +0 -0
- data/public/images/iqvoc/footer.png +0 -0
- data/public/images/iqvoc/go_there.png +0 -0
- data/public/images/iqvoc/header.png +0 -0
- data/public/images/iqvoc/header_long.png +0 -0
- data/public/images/iqvoc/iqvoc.png +0 -0
- data/public/images/iqvoc/note_add.png +0 -0
- data/public/images/iqvoc/note_delete.png +0 -0
- data/public/images/iqvoc/note_edit.png +0 -0
- data/public/images/iqvoc/ok.png +0 -0
- data/public/images/iqvoc/rails.png +0 -0
- data/public/images/iqvoc/rdf_flyer.gif +0 -0
- data/public/images/iqvoc/red_arrow.png +0 -0
- data/public/images/iqvoc/remove.png +0 -0
- data/public/images/iqvoc/shadow.png +0 -0
- data/public/images/iqvoc/spinner.gif +0 -0
- data/public/images/iqvoc/tokenizer_delete.png +0 -0
- data/public/images/iqvoc/tokenizer_pencile.png +0 -0
- data/public/images/iqvoc/tokenizer_show.png +0 -0
- data/public/images/iqvoc/unfinished.png +0 -0
- data/public/javascripts/iqvoc/application.js +123 -0
- data/public/javascripts/iqvoc/entityselect.js +121 -0
- data/public/javascripts/iqvoc/excanvas.js +35 -0
- data/public/javascripts/iqvoc/iqvoc.js +118 -0
- data/public/javascripts/iqvoc/jit_rgraph.js +153 -0
- data/public/javascripts/iqvoc/jquery-1.6.2.min.js +18 -0
- data/public/javascripts/iqvoc/jquery-treeview/changelog.txt +29 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/async.html +44 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/bg.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/demo.js +43 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/images.html +56 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/index.html +340 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/large.html +559 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/prerendered.html +621 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/screen.css +24 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/simple.html +82 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/source.php +87 -0
- data/public/javascripts/iqvoc/jquery-treeview/demo/source.phps +87 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/ajax-loader.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/file.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/folder-closed.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/folder.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/minus.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/plus.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-black-line.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-black.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-default-line.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-default.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-famfamfam-line.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-famfamfam.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-gray-line.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-gray.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-red-line.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/images/treeview-red.gif +0 -0
- data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.async.js +82 -0
- data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.css +75 -0
- data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.js +251 -0
- data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.min.js +15 -0
- data/public/javascripts/iqvoc/jquery-treeview/jquery.treeview.pack.js +16 -0
- data/public/javascripts/iqvoc/jquery-treeview/lib/jquery.cookie.js +92 -0
- data/public/javascripts/iqvoc/jquery-treeview/lib/jquery.js +3363 -0
- data/public/javascripts/iqvoc/jquery-treeview/todo +8 -0
- data/public/javascripts/iqvoc/jquery-ui-1.8.13.custom.js +3229 -0
- data/public/javascripts/iqvoc/jquery-ui-1.8.13.custom.min.js +163 -0
- data/public/javascripts/iqvoc/jquery-ui.datepicker-de.js +22 -0
- data/public/javascripts/iqvoc/json2.js +480 -0
- data/public/javascripts/iqvoc/langselect.js +73 -0
- data/public/javascripts/iqvoc/rails.js +132 -0
- data/public/javascripts/iqvoc/storage.js +122 -0
- data/public/javascripts/iqvoc/visualization.js +321 -0
- data/public/robots.txt +5 -0
- data/public/stylesheets/iqvoc/blueprint/ie.css +35 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/buttons/icons/cross.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/buttons/icons/key.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/buttons/icons/tick.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/buttons/readme.txt +32 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/buttons/screen.css +97 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/fancy-type/readme.txt +14 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/fancy-type/screen.css +71 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/doc.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/email.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/external.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/feed.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/im.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/pdf.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/visited.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/icons/xls.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/readme.txt +18 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/link-icons/screen.css +40 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/rtl/readme.txt +10 -0
- data/public/stylesheets/iqvoc/blueprint/plugins/rtl/screen.css +110 -0
- data/public/stylesheets/iqvoc/blueprint/print.css +29 -0
- data/public/stylesheets/iqvoc/blueprint/screen.css +258 -0
- data/public/stylesheets/iqvoc/blueprint/src/forms.css +65 -0
- data/public/stylesheets/iqvoc/blueprint/src/grid.css +280 -0
- data/public/stylesheets/iqvoc/blueprint/src/grid.png +0 -0
- data/public/stylesheets/iqvoc/blueprint/src/ie.css +76 -0
- data/public/stylesheets/iqvoc/blueprint/src/print.css +85 -0
- data/public/stylesheets/iqvoc/blueprint/src/reset.css +45 -0
- data/public/stylesheets/iqvoc/blueprint/src/typography.css +106 -0
- data/public/stylesheets/iqvoc/forms.css +71 -0
- data/public/stylesheets/iqvoc/images/back.png +0 -0
- data/public/stylesheets/iqvoc/images/branch.png +0 -0
- data/public/stylesheets/iqvoc/images/categ.png +0 -0
- data/public/stylesheets/iqvoc/images/categ_open.png +0 -0
- data/public/stylesheets/iqvoc/images/go_there.png +0 -0
- data/public/stylesheets/iqvoc/images/iqvoc.png +0 -0
- data/public/stylesheets/iqvoc/images/leaf_end.png +0 -0
- data/public/stylesheets/iqvoc/images/leaf_end_filled.png +0 -0
- data/public/stylesheets/iqvoc/images/leaf_mid.png +0 -0
- data/public/stylesheets/iqvoc/images/leaf_mid_filled.png +0 -0
- data/public/stylesheets/iqvoc/images/leaf_nothing.png +0 -0
- data/public/stylesheets/iqvoc/images/leaf_only.png +0 -0
- data/public/stylesheets/iqvoc/images/leaf_only_filled.png +0 -0
- data/public/stylesheets/iqvoc/images/leaf_top.png +0 -0
- data/public/stylesheets/iqvoc/images/leaf_top_filled.png +0 -0
- data/public/stylesheets/iqvoc/images/nothing.png +0 -0
- data/public/stylesheets/iqvoc/images/top_01.png +0 -0
- data/public/stylesheets/iqvoc/images/trunk.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-bg_flat_55_fbec88_40x100.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-bg_glass_75_d0e5f5_1x400.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-bg_glass_85_dfeffc_1x400.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-bg_gloss-wave_55_5c9ccc_500x100.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-bg_inset-hard_100_f5f8f9_1x100.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-bg_inset-hard_100_fcfdfd_1x100.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-icons_217bc0_256x240.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-icons_2e83ff_256x240.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-icons_469bdd_256x240.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-icons_6da8d5_256x240.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-icons_cd0a0a_256x240.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-icons_d8e7f3_256x240.png +0 -0
- data/public/stylesheets/iqvoc/images/ui-icons_f9bd01_256x240.png +0 -0
- data/public/stylesheets/iqvoc/iqvoc.css +477 -0
- data/public/stylesheets/iqvoc/jquery-ui-1.8.13.custom.css +415 -0
- data/public/stylesheets/iqvoc/widgets.css +81 -0
- data/test/factories.rb +74 -0
- data/test/integration/alphabetical_test.rb +53 -0
- data/test/integration/authentication_test.rb +41 -0
- data/test/integration/browse_concepts_and_labels_test.rb +61 -0
- data/test/integration/browse_static_pages_test.rb +29 -0
- data/test/integration/client_augmentation_test.rb +42 -0
- data/test/integration/client_edit_concept_test.rb +72 -0
- data/test/integration/collection_circularity_test.rb +110 -0
- data/test/integration/concept_test.rb +61 -0
- data/test/integration/edit_concepts_test.rb +40 -0
- data/test/integration/note_annotations_test.rb +86 -0
- data/test/integration/search_test.rb +205 -0
- data/test/integration/tree_test.rb +31 -0
- data/test/integration/untranslated_test.rb +60 -0
- data/test/integration_test_helper.rb +45 -0
- data/test/performance/browsing_test.rb +25 -0
- data/test/test_helper.rb +29 -0
- data/test/unit/concept_test.rb +93 -0
- data/test/unit/note_test.rb +32 -0
- data/test/unit/origin_mapping_test.rb +70 -0
- data/test/unit/skos_import_test.rb +100 -0
- metadata +522 -0
@@ -0,0 +1,122 @@
|
|
1
|
+
/*
|
2
|
+
Copyright (c) 2010 Remy Sharp, http://remysharp.com
|
3
|
+
|
4
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
5
|
+
a copy of this software and associated documentation files (the
|
6
|
+
"Software"), to deal in the Software without restriction, including
|
7
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
8
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
9
|
+
permit persons to whom the Software is furnished to do so, subject to
|
10
|
+
the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be
|
13
|
+
included in all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
16
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
17
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
18
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
19
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
20
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
21
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
22
|
+
*/
|
23
|
+
if (typeof window.localStorage == 'undefined' || typeof window.sessionStorage == 'undefined') (function () {
|
24
|
+
|
25
|
+
var Storage = function (type) {
|
26
|
+
function createCookie(name, value, days) {
|
27
|
+
var date, expires;
|
28
|
+
|
29
|
+
if (days) {
|
30
|
+
date = new Date();
|
31
|
+
date.setTime(date.getTime()+(days*24*60*60*1000));
|
32
|
+
expires = "; expires="+date.toGMTString();
|
33
|
+
} else {
|
34
|
+
expires = "";
|
35
|
+
}
|
36
|
+
document.cookie = name+"="+value+expires+"; path=/";
|
37
|
+
}
|
38
|
+
|
39
|
+
function readCookie(name) {
|
40
|
+
var nameEQ = name + "=",
|
41
|
+
ca = document.cookie.split(';'),
|
42
|
+
i, c;
|
43
|
+
|
44
|
+
for (i=0; i < ca.length; i++) {
|
45
|
+
c = ca[i];
|
46
|
+
while (c.charAt(0)==' ') {
|
47
|
+
c = c.substring(1,c.length);
|
48
|
+
}
|
49
|
+
|
50
|
+
if (c.indexOf(nameEQ) == 0) {
|
51
|
+
return c.substring(nameEQ.length,c.length);
|
52
|
+
}
|
53
|
+
}
|
54
|
+
return null;
|
55
|
+
}
|
56
|
+
|
57
|
+
function setData(data) {
|
58
|
+
data = JSON.stringify(data);
|
59
|
+
if (type == 'session') {
|
60
|
+
window.name = data;
|
61
|
+
} else {
|
62
|
+
createCookie('localStorage', data, 365);
|
63
|
+
}
|
64
|
+
}
|
65
|
+
|
66
|
+
function clearData() {
|
67
|
+
if (type == 'session') {
|
68
|
+
window.name = '';
|
69
|
+
} else {
|
70
|
+
createCookie('localStorage', '', 365);
|
71
|
+
}
|
72
|
+
}
|
73
|
+
|
74
|
+
function getData() {
|
75
|
+
var data = type == 'session' ? window.name : readCookie('localStorage');
|
76
|
+
try {
|
77
|
+
return data ? JSON.parse(data) : {};
|
78
|
+
} catch(exc) { // bad cookie data -- XXX: hack by FND
|
79
|
+
return {}
|
80
|
+
}
|
81
|
+
}
|
82
|
+
|
83
|
+
|
84
|
+
// initialise if there's already data
|
85
|
+
var data = getData();
|
86
|
+
|
87
|
+
return {
|
88
|
+
length: 0,
|
89
|
+
clear: function () {
|
90
|
+
data = {};
|
91
|
+
this.length = 0;
|
92
|
+
clearData();
|
93
|
+
},
|
94
|
+
getItem: function (key) {
|
95
|
+
return data[key] === undefined ? null : data[key];
|
96
|
+
},
|
97
|
+
key: function (i) {
|
98
|
+
// not perfect, but works
|
99
|
+
var ctr = 0;
|
100
|
+
for (var k in data) {
|
101
|
+
if (ctr == i) return k;
|
102
|
+
else ctr++;
|
103
|
+
}
|
104
|
+
return null;
|
105
|
+
},
|
106
|
+
removeItem: function (key) {
|
107
|
+
delete data[key];
|
108
|
+
this.length--;
|
109
|
+
setData(data);
|
110
|
+
},
|
111
|
+
setItem: function (key, value) {
|
112
|
+
data[key] = value+''; // forces the value to a string
|
113
|
+
this.length++;
|
114
|
+
setData(data);
|
115
|
+
}
|
116
|
+
};
|
117
|
+
};
|
118
|
+
|
119
|
+
if (typeof window.localStorage == 'undefined') window.localStorage = new Storage('local');
|
120
|
+
if (typeof window.sessionStorage == 'undefined') window.sessionStorage = new Storage('session');
|
121
|
+
|
122
|
+
})();
|
@@ -0,0 +1,321 @@
|
|
1
|
+
/*jslint vars: true, unparam: true, nomen: true, browser: true */
|
2
|
+
/*global jQuery, $jit, IQVOC, HTMLCanvasElement */
|
3
|
+
|
4
|
+
// basic settings -- XXX: cargo-culted from JIT examples
|
5
|
+
var labelType, nativeTextSupport, useGradients, animate; // XXX: useless globals!?
|
6
|
+
(function() {
|
7
|
+
"use strict";
|
8
|
+
|
9
|
+
var ua = navigator.userAgent,
|
10
|
+
iOS = ua.match(/iPhone/i) || ua.match(/iPad/i),
|
11
|
+
typeOfCanvas = typeof HTMLCanvasElement,
|
12
|
+
nativeCanvasSupport = (typeOfCanvas === "object" || typeOfCanvas === "function"),
|
13
|
+
textSupport = nativeCanvasSupport
|
14
|
+
&& (typeof document.createElement("canvas").getContext("2d").fillText === "function");
|
15
|
+
// settings based on the fact that ExCanvas provides text support for IE
|
16
|
+
// and that as of today iPhone/iPad current text support is lame
|
17
|
+
labelType = (!nativeCanvasSupport || (textSupport && !iOS)) ? "Native" : "HTML";
|
18
|
+
nativeTextSupport = labelType === "Native";
|
19
|
+
useGradients = nativeCanvasSupport;
|
20
|
+
animate = !(iOS || !nativeCanvasSupport);
|
21
|
+
}());
|
22
|
+
|
23
|
+
IQVOC.visualization = (function($) {
|
24
|
+
|
25
|
+
"use strict";
|
26
|
+
|
27
|
+
var LEVELDISTANCE = 100;
|
28
|
+
var CONCEPT_URI;
|
29
|
+
var MAX_CHILDREN = 10; // TODO: rename
|
30
|
+
var VIZ; // XXX: singleton; hacky - there should be a more elegant way!?
|
31
|
+
|
32
|
+
var spawn, redraw, onFilter, generateGraph, transformData, generateConceptNode,
|
33
|
+
generateLabelNode, generateDummyConcepts, groupChildNodes,
|
34
|
+
determineTransparency, htmlEncode;
|
35
|
+
|
36
|
+
var init = function(container, callback) { // TODO: should be a class so multiple instances can be created (should also avoid module-level globals)
|
37
|
+
CONCEPT_URI = $("head link[type='application/json']").attr("href"); // XXX: should be passed in via argument? (encapsulation)
|
38
|
+
$.getJSON(CONCEPT_URI, function(data, status, xhr) {
|
39
|
+
data = transformData(data);
|
40
|
+
container = spawn(container, data);
|
41
|
+
VIZ = container.data("widget");
|
42
|
+
if(callback) {
|
43
|
+
callback(container);
|
44
|
+
}
|
45
|
+
});
|
46
|
+
};
|
47
|
+
|
48
|
+
// container can be an ID or a DOM element
|
49
|
+
spawn = function(container, data) {
|
50
|
+
container = container.nodeType ? container : document.getElementById(container);
|
51
|
+
|
52
|
+
// zoom controls
|
53
|
+
$.each(["+", "-"], function(i, item) {
|
54
|
+
$('<input type="button" class="button" />').val(item).click(function(ev) {
|
55
|
+
var d = VIZ.config.Navigation.zooming / 1000;
|
56
|
+
d = item === "-" ? 1 - d : 1 + d;
|
57
|
+
VIZ.canvas.scale(d, d);
|
58
|
+
}).appendTo(container);
|
59
|
+
});
|
60
|
+
// filter controls
|
61
|
+
$.each(["label", "relation"], function(i, item) {
|
62
|
+
var cb = $('<input type="checkbox" name="entities" checked="checked">')
|
63
|
+
.val(item);
|
64
|
+
$('<label />').text(item + "s").prepend(cb).appendTo(container);
|
65
|
+
});
|
66
|
+
$("input[type=checkbox]", container).live("change", onFilter);
|
67
|
+
// resize controls
|
68
|
+
var toggleSize;
|
69
|
+
var btns = $.map(["▢", "_"], function(item, i) {
|
70
|
+
return $('<input type="button" class="button" />').val(item)
|
71
|
+
.click(function(ev) { toggleSize(i === 0); })
|
72
|
+
.prependTo(container)[0];
|
73
|
+
});
|
74
|
+
btns = $(btns);
|
75
|
+
btns.eq(1).hide();
|
76
|
+
toggleSize = (function(container) {
|
77
|
+
container = $(container);
|
78
|
+
var width = container.width();
|
79
|
+
var height = container.height();
|
80
|
+
return function(enlarge) {
|
81
|
+
var viz = container.data("widget"),
|
82
|
+
_width = enlarge ? width * 2 : width,
|
83
|
+
_height = enlarge ? height * 2 : height;
|
84
|
+
viz.canvas.resize(_width, _height);
|
85
|
+
container.css({
|
86
|
+
width: String(_width) + "px",
|
87
|
+
height: String(_height) + "px"
|
88
|
+
});
|
89
|
+
IQVOC.visualization.redraw(viz);
|
90
|
+
|
91
|
+
btns.toggle();
|
92
|
+
IQVOC.Storage.setItem("visualization", enlarge ? "enlarged" : "");
|
93
|
+
};
|
94
|
+
}(container));
|
95
|
+
|
96
|
+
var viz = generateGraph(container, { levelDistance: LEVELDISTANCE });
|
97
|
+
viz.filters = []; // TODO: rename? (ambiguous)
|
98
|
+
viz.data = data;
|
99
|
+
viz.toggleSize = toggleSize;
|
100
|
+
redraw(viz);
|
101
|
+
|
102
|
+
return $(container).addClass("infovis").data("widget", viz);
|
103
|
+
};
|
104
|
+
|
105
|
+
redraw = function(viz) {
|
106
|
+
viz.graph.empty();
|
107
|
+
viz.labels.clearLabels();
|
108
|
+
viz.loadJSON(viz.data);
|
109
|
+
viz.refresh();
|
110
|
+
};
|
111
|
+
|
112
|
+
onFilter = function(ev) {
|
113
|
+
var el = $(this),
|
114
|
+
checked = el.attr("checked"),
|
115
|
+
value = el.val();
|
116
|
+
|
117
|
+
if(checked) {
|
118
|
+
var pos = $.inArray(value, VIZ.filters);
|
119
|
+
VIZ.filters.splice(pos, 1);
|
120
|
+
} else {
|
121
|
+
VIZ.filters.push(value);
|
122
|
+
}
|
123
|
+
|
124
|
+
el.closest(".infovis").toggleClass("filtered", VIZ.filters.length > 0);
|
125
|
+
|
126
|
+
VIZ.loadJSON(VIZ.data);
|
127
|
+
VIZ.refresh();
|
128
|
+
};
|
129
|
+
|
130
|
+
generateGraph = function(container, options) {
|
131
|
+
options = $.extend(options, {
|
132
|
+
injectInto: container,
|
133
|
+
|
134
|
+
Navigation: {
|
135
|
+
enable: true,
|
136
|
+
panning: "avoid nodes",
|
137
|
+
zooming: 100
|
138
|
+
},
|
139
|
+
|
140
|
+
width: container.offsetWidth,
|
141
|
+
height: container.offsetHeight,
|
142
|
+
|
143
|
+
levelDistance: options.levelDistance || LEVELDISTANCE,
|
144
|
+
|
145
|
+
// concentric circle as background (cargo-culted from RGraph example)
|
146
|
+
background: {
|
147
|
+
CanvasStyles: {
|
148
|
+
strokeStyle: "#AAA",
|
149
|
+
shadowBlur: 50
|
150
|
+
//shadowColor: "#EEE" // XXX: fills entire background in Chrome!?
|
151
|
+
}
|
152
|
+
},
|
153
|
+
// styles
|
154
|
+
Node: {
|
155
|
+
overridable: true,
|
156
|
+
dim: 5,
|
157
|
+
color: "#B0EAA4"
|
158
|
+
},
|
159
|
+
Edge: {
|
160
|
+
overridable: true,
|
161
|
+
lineWidth: 2,
|
162
|
+
color: "#888"
|
163
|
+
},
|
164
|
+
|
165
|
+
// add text and attach event handlers to labels
|
166
|
+
onCreateLabel: function(domEl, node) {
|
167
|
+
var name = htmlEncode(node.name);
|
168
|
+
if(node.data.nodes) { // special-casing placeholder
|
169
|
+
$(domEl).html(node.name)
|
170
|
+
.attr("title", String(node.data.nodes.length) + " nodes hidden"); // TODO: i18n
|
171
|
+
} else if(node.data.etype === "label") {
|
172
|
+
$(domEl).html(name);
|
173
|
+
} else { // concept node (link with abbreviated name)
|
174
|
+
var cue = "/concepts/";
|
175
|
+
var host = CONCEPT_URI.split(cue)[0]; // XXX: hacky and brittle
|
176
|
+
var caption = node.name.length <= 5 ? name :
|
177
|
+
htmlEncode(node.name.substr(0, 5)) + "…";
|
178
|
+
$("<a />").attr("href", host + cue + node.id)
|
179
|
+
.attr("title", name).html(caption)
|
180
|
+
.appendTo(domEl);
|
181
|
+
}
|
182
|
+
},
|
183
|
+
|
184
|
+
// change node styles when labels are placed/moved
|
185
|
+
onPlaceLabel: function(domEl, node) {
|
186
|
+
var css = {},
|
187
|
+
el = $(domEl),
|
188
|
+
classes = ["level" + String(node._depth),
|
189
|
+
node.data.etype || "concept"];
|
190
|
+
// ensure label covers the underlying node
|
191
|
+
css.height = css.lineHeight = String(node.Node.height) + "px";
|
192
|
+
el.addClass(classes.join(" ")).css(css);
|
193
|
+
|
194
|
+
// ensure label is centered on the symbol
|
195
|
+
var style = domEl.style;
|
196
|
+
var x = parseInt(style.left, 10);
|
197
|
+
var y = parseInt(style.top, 10);
|
198
|
+
style.top = String(y - domEl.offsetHeight / 2) + "px";
|
199
|
+
style.left = String(x - domEl.offsetWidth / 2) + "px";
|
200
|
+
},
|
201
|
+
|
202
|
+
onBeforePlotLine: function(adj) {
|
203
|
+
if(adj.nodeTo.data.etype === "label") {
|
204
|
+
adj.nodeTo.data.$type = "square";
|
205
|
+
adj.nodeTo.data.$color = "#EEE";
|
206
|
+
adj.data.$lineWidth = adj.Edge.lineWidth / 2;
|
207
|
+
adj.data.$color = "#00A";
|
208
|
+
adj.data.$alpha = 0.5;
|
209
|
+
} else {
|
210
|
+
var node = adj.nodeTo; // nodeTo is always the inner node!?
|
211
|
+
var alpha = determineTransparency(node._depth);
|
212
|
+
if(alpha) {
|
213
|
+
node.setData("alpha", alpha);
|
214
|
+
adj.setData("alpha", alpha);
|
215
|
+
}
|
216
|
+
}
|
217
|
+
|
218
|
+
$.each([adj.nodeFrom, adj.nodeTo], function(i, node) { // XXX: inefficient and fugly
|
219
|
+
var etype = node.data ? node.data.etype : null;
|
220
|
+
if(VIZ) {
|
221
|
+
var hideRelations = $.inArray("relation", VIZ.filters) !== -1;
|
222
|
+
var rootLabel = node._depth === 1 && etype === "label";
|
223
|
+
if((hideRelations && node._depth > 0 && !rootLabel) ||
|
224
|
+
(etype && $.inArray(etype, VIZ.filters) !== -1)) {
|
225
|
+
adj.data.$alpha = 0;
|
226
|
+
node.data.$alpha = 0;
|
227
|
+
}
|
228
|
+
}
|
229
|
+
});
|
230
|
+
}
|
231
|
+
});
|
232
|
+
return new $jit.RGraph(options);
|
233
|
+
};
|
234
|
+
|
235
|
+
// create a JIT-compatible JSON tree structure from a concept representation
|
236
|
+
transformData = function(concept) {
|
237
|
+
return generateConceptNode(concept);
|
238
|
+
};
|
239
|
+
|
240
|
+
// generate node from iQvoc concept representation
|
241
|
+
generateConceptNode = function(concept) {
|
242
|
+
if(typeof concept.relations === "number") {
|
243
|
+
concept.relations = generateDummyConcepts(concept.relations);
|
244
|
+
}
|
245
|
+
var labels = $.map(concept.labels || [], generateLabelNode);
|
246
|
+
groupChildNodes(labels, "label");
|
247
|
+
var relations = $.map(concept.relations || [], generateConceptNode);
|
248
|
+
groupChildNodes(relations);
|
249
|
+
// combine labels and relations in alternating order
|
250
|
+
var children = $.map(labels, function(label, i) {
|
251
|
+
return relations.length ? [label, relations.pop()] : label;
|
252
|
+
}).concat(relations);
|
253
|
+
return {
|
254
|
+
id: concept.origin,
|
255
|
+
name: labels.length ? labels[0].name : "", // XXX: should use actual pref label
|
256
|
+
children: children
|
257
|
+
};
|
258
|
+
};
|
259
|
+
|
260
|
+
// generate node from iQvoc label representation
|
261
|
+
generateLabelNode = function(label) {
|
262
|
+
return {
|
263
|
+
id: label.origin || Math.random(),
|
264
|
+
name: label.value,
|
265
|
+
data: { etype: "label" }
|
266
|
+
// TODO: relations to other concepts (XL only)
|
267
|
+
};
|
268
|
+
};
|
269
|
+
|
270
|
+
// generate dummy iQvoc label representations
|
271
|
+
generateDummyConcepts = function(count) {
|
272
|
+
return $.map(new Array(count), function(item, i) {
|
273
|
+
return { origin: Math.random() };
|
274
|
+
});
|
275
|
+
};
|
276
|
+
|
277
|
+
// combine excessive child nodes in a single placeholder node
|
278
|
+
groupChildNodes = function(nodes, etype) { // TODO: rename
|
279
|
+
if(nodes.length > MAX_CHILDREN) {
|
280
|
+
var excess = nodes.splice(MAX_CHILDREN - 1);
|
281
|
+
var placeholder = {
|
282
|
+
id: Math.random(),
|
283
|
+
name: "…",
|
284
|
+
data: { nodes: excess } // XXX: property name ambiguous?
|
285
|
+
};
|
286
|
+
if(etype) {
|
287
|
+
placeholder.data.etype = etype;
|
288
|
+
}
|
289
|
+
nodes.push(placeholder);
|
290
|
+
}
|
291
|
+
};
|
292
|
+
|
293
|
+
determineTransparency = function(depth) {
|
294
|
+
if(depth === 2) {
|
295
|
+
return 0.6;
|
296
|
+
} else if(depth > 2) {
|
297
|
+
return 0.3;
|
298
|
+
}
|
299
|
+
};
|
300
|
+
|
301
|
+
// hijack setPos method to reduce the relative distance for label nodes -- XXX: modifies all Node instances!
|
302
|
+
var _setPos = $jit.Graph.Node.prototype.setPos;
|
303
|
+
$jit.Graph.Node.prototype.setPos = function(value, type) {
|
304
|
+
if(this.data.etype === "label") {
|
305
|
+
value.rho = value.rho - (LEVELDISTANCE * 0.5);
|
306
|
+
}
|
307
|
+
return _setPos.apply(this, arguments);
|
308
|
+
};
|
309
|
+
|
310
|
+
// convert &, <, > and " to HTML entities (adapted from TiddlyWiki)
|
311
|
+
htmlEncode = function(str) {
|
312
|
+
return str.replace(/&/mg, "&").replace(/</mg, "<")
|
313
|
+
.replace(/>/mg, ">").replace(/\"/mg, """);
|
314
|
+
};
|
315
|
+
|
316
|
+
return {
|
317
|
+
init: init,
|
318
|
+
redraw: redraw
|
319
|
+
};
|
320
|
+
|
321
|
+
}(jQuery));
|
data/public/robots.txt
ADDED
@@ -0,0 +1,35 @@
|
|
1
|
+
/* -----------------------------------------------------------------------
|
2
|
+
|
3
|
+
|
4
|
+
Blueprint CSS Framework 0.9
|
5
|
+
http://blueprintcss.org
|
6
|
+
|
7
|
+
* Copyright (c) 2007-Present. See LICENSE for more info.
|
8
|
+
* See README for instructions on how to use Blueprint.
|
9
|
+
* For credits and origins, see AUTHORS.
|
10
|
+
* This is a compressed file. See the sources in the 'src' directory.
|
11
|
+
|
12
|
+
----------------------------------------------------------------------- */
|
13
|
+
|
14
|
+
/* ie.css */
|
15
|
+
body {text-align:center;}
|
16
|
+
.container {text-align:left;}
|
17
|
+
* html .column, * html .span-1, * html .span-2, * html .span-3, * html .span-4, * html .span-5, * html .span-6, * html .span-7, * html .span-8, * html .span-9, * html .span-10, * html .span-11, * html .span-12, * html .span-13, * html .span-14, * html .span-15, * html .span-16, * html .span-17, * html .span-18, * html .span-19, * html .span-20, * html .span-21, * html .span-22, * html .span-23, * html .span-24 {display:inline;overflow-x:hidden;}
|
18
|
+
* html legend {margin:0px -8px 16px 0;padding:0;}
|
19
|
+
sup {vertical-align:text-top;}
|
20
|
+
sub {vertical-align:text-bottom;}
|
21
|
+
html>body p code {*white-space:normal;}
|
22
|
+
hr {margin:-8px auto 11px;}
|
23
|
+
img {-ms-interpolation-mode:bicubic;}
|
24
|
+
.clearfix, .container {display:inline-block;}
|
25
|
+
* html .clearfix, * html .container {height:1%;}
|
26
|
+
fieldset {padding-top:0;}
|
27
|
+
textarea {overflow:auto;}
|
28
|
+
input.text, input.title, textarea {background-color:#fff;border:1px solid #bbb;}
|
29
|
+
input.text:focus, input.title:focus {border-color:#666;}
|
30
|
+
input.text, input.title, textarea, select {margin:0.5em 0;}
|
31
|
+
input.checkbox, input.radio {position:relative;top:.25em;}
|
32
|
+
form.inline div, form.inline p {vertical-align:middle;}
|
33
|
+
form.inline label {position:relative;top:-0.25em;}
|
34
|
+
form.inline input.checkbox, form.inline input.radio, form.inline input.button, form.inline button {margin:0.5em 0;}
|
35
|
+
button, input.button {position:relative;top:0.25em;}
|
Binary file
|
Binary file
|
Binary file
|
@@ -0,0 +1,32 @@
|
|
1
|
+
Buttons
|
2
|
+
|
3
|
+
* Gives you great looking CSS buttons, for both <a> and <button>.
|
4
|
+
* Demo: particletree.com/features/rediscovering-the-button-element
|
5
|
+
|
6
|
+
|
7
|
+
Credits
|
8
|
+
----------------------------------------------------------------
|
9
|
+
|
10
|
+
* Created by Kevin Hale [particletree.com]
|
11
|
+
* Adapted for Blueprint by Olav Bjorkoy [bjorkoy.com]
|
12
|
+
|
13
|
+
|
14
|
+
Usage
|
15
|
+
----------------------------------------------------------------
|
16
|
+
|
17
|
+
1) Add this plugin to lib/settings.yml.
|
18
|
+
See compress.rb for instructions.
|
19
|
+
|
20
|
+
2) Use the following HTML code to place the buttons on your site:
|
21
|
+
|
22
|
+
<button type="submit" class="button positive">
|
23
|
+
<img src="css/blueprint/plugins/buttons/icons/tick.png" alt=""/> Save
|
24
|
+
</button>
|
25
|
+
|
26
|
+
<a class="button" href="/password/reset/">
|
27
|
+
<img src="css/blueprint/plugins/buttons/icons/key.png" alt=""/> Change Password
|
28
|
+
</a>
|
29
|
+
|
30
|
+
<a href="#" class="button negative">
|
31
|
+
<img src="css/blueprint/plugins/buttons/icons/cross.png" alt=""/> Cancel
|
32
|
+
</a>
|
@@ -0,0 +1,97 @@
|
|
1
|
+
/* --------------------------------------------------------------
|
2
|
+
|
3
|
+
buttons.css
|
4
|
+
* Gives you some great CSS-only buttons.
|
5
|
+
|
6
|
+
Created by Kevin Hale [particletree.com]
|
7
|
+
* particletree.com/features/rediscovering-the-button-element
|
8
|
+
|
9
|
+
See Readme.txt in this folder for instructions.
|
10
|
+
|
11
|
+
-------------------------------------------------------------- */
|
12
|
+
|
13
|
+
a.button, button {
|
14
|
+
display:block;
|
15
|
+
float:left;
|
16
|
+
margin: 0.7em 0.5em 0.7em 0;
|
17
|
+
padding:5px 10px 5px 7px; /* Links */
|
18
|
+
|
19
|
+
border:1px solid #dedede;
|
20
|
+
border-top:1px solid #eee;
|
21
|
+
border-left:1px solid #eee;
|
22
|
+
|
23
|
+
background-color:#f5f5f5;
|
24
|
+
font-family:"Lucida Grande", Tahoma, Arial, Verdana, sans-serif;
|
25
|
+
font-size:100%;
|
26
|
+
line-height:130%;
|
27
|
+
text-decoration:none;
|
28
|
+
font-weight:bold;
|
29
|
+
color:#565656;
|
30
|
+
cursor:pointer;
|
31
|
+
}
|
32
|
+
button {
|
33
|
+
width:auto;
|
34
|
+
overflow:visible;
|
35
|
+
padding:4px 10px 3px 7px; /* IE6 */
|
36
|
+
}
|
37
|
+
button[type] {
|
38
|
+
padding:4px 10px 4px 7px; /* Firefox */
|
39
|
+
line-height:17px; /* Safari */
|
40
|
+
}
|
41
|
+
*:first-child+html button[type] {
|
42
|
+
padding:4px 10px 3px 7px; /* IE7 */
|
43
|
+
}
|
44
|
+
button img, a.button img{
|
45
|
+
margin:0 3px -3px 0 !important;
|
46
|
+
padding:0;
|
47
|
+
border:none;
|
48
|
+
width:16px;
|
49
|
+
height:16px;
|
50
|
+
float:none;
|
51
|
+
}
|
52
|
+
|
53
|
+
|
54
|
+
/* Button colors
|
55
|
+
-------------------------------------------------------------- */
|
56
|
+
|
57
|
+
/* Standard */
|
58
|
+
button:hover, a.button:hover{
|
59
|
+
background-color:#dff4ff;
|
60
|
+
border:1px solid #c2e1ef;
|
61
|
+
color:#336699;
|
62
|
+
}
|
63
|
+
a.button:active{
|
64
|
+
background-color:#6299c5;
|
65
|
+
border:1px solid #6299c5;
|
66
|
+
color:#fff;
|
67
|
+
}
|
68
|
+
|
69
|
+
/* Positive */
|
70
|
+
body .positive {
|
71
|
+
color:#529214;
|
72
|
+
}
|
73
|
+
a.positive:hover, button.positive:hover {
|
74
|
+
background-color:#E6EFC2;
|
75
|
+
border:1px solid #C6D880;
|
76
|
+
color:#529214;
|
77
|
+
}
|
78
|
+
a.positive:active {
|
79
|
+
background-color:#529214;
|
80
|
+
border:1px solid #529214;
|
81
|
+
color:#fff;
|
82
|
+
}
|
83
|
+
|
84
|
+
/* Negative */
|
85
|
+
body .negative {
|
86
|
+
color:#d12f19;
|
87
|
+
}
|
88
|
+
a.negative:hover, button.negative:hover {
|
89
|
+
background-color:#fbe3e4;
|
90
|
+
border:1px solid #fbc2c4;
|
91
|
+
color:#d12f19;
|
92
|
+
}
|
93
|
+
a.negative:active {
|
94
|
+
background-color:#d12f19;
|
95
|
+
border:1px solid #d12f19;
|
96
|
+
color:#fff;
|
97
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
Fancy Type
|
2
|
+
|
3
|
+
* Gives you classes to use if you'd like some
|
4
|
+
extra fancy typography.
|
5
|
+
|
6
|
+
Credits and instructions are specified above each class
|
7
|
+
in the fancy-type.css file in this directory.
|
8
|
+
|
9
|
+
|
10
|
+
Usage
|
11
|
+
----------------------------------------------------------------
|
12
|
+
|
13
|
+
1) Add this plugin to lib/settings.yml.
|
14
|
+
See compress.rb for instructions.
|