rename class to className in views

This commit is contained in:
Connor Turland 2018-03-05 12:33:16 -05:00
parent 5f4a789435
commit d910094d76
37 changed files with 432 additions and 432 deletions

View file

@ -1,5 +1,5 @@
{- submit_btn_css ||= 'button red-button' } {- submit_btn_css ||= 'button red-button' }
{ form_tag oauth_application_path(application) do } { form_tag oauth_application_path(application) do }
<input type="hidden" name="_method" value="delete"> <input type="hidden" name="_method" value="delete">
{ submit_tag t('doorkeeper.applications.buttons.destroy'), onclick: "return confirm('#{ t('doorkeeper.applications.confirmations.destroy') }')", class: submit_btn_css } { submit_tag t('doorkeeper.applications.buttons.destroy'), onclick: "return confirm('#{ t('doorkeeper.applications.confirmations.destroy') }')", className: submit_btn_css }
{ end } { end }

View file

@ -1,36 +1,36 @@
{ form_for application, url: doorkeeper_submit_path(application), html: {class: 'form-horizontal', role: 'form'} do |f| } { form_for application, url: doorkeeper_submit_path(application), html: {className: 'form-horizontal', role: 'form'} do |f| }
{ if application.errors.any? } { if application.errors.any? }
<div class="alert alert-danger" data-alert><p>{ t('doorkeeper.applications.form.error') }</p></div> <div className="alert alert-danger" data-alert><p>{ t('doorkeeper.applications.form.error') }</p></div>
{ end } { end }
{ content_tag :div, class: "form-group#{' has-error' if application.errors[:name].present?}" do } { content_tag :div, className: "form-group#{' has-error' if application.errors[:name].present?}" do }
{ f.label :name, class: 'col-sm-2 control-label' } { f.label :name, className: 'col-sm-2 control-label' }
<div class="col-sm-10"> <div className="col-sm-10">
{ f.text_field :name, class: 'form-control' } { f.text_field :name, className: 'form-control' }
{ doorkeeper_errors_for application, :name } { doorkeeper_errors_for application, :name }
</div> </div>
{ end } { end }
{ content_tag :div, class: "form-group#{' has-error' if application.errors[:redirect_uri].present?}" do } { content_tag :div, className: "form-group#{' has-error' if application.errors[:redirect_uri].present?}" do }
{ f.label :redirect_uri, class: 'col-sm-2 control-label' } { f.label :redirect_uri, className: 'col-sm-2 control-label' }
<div class="col-sm-10"> <div className="col-sm-10">
{ f.text_area :redirect_uri, class: 'form-control' } { f.text_area :redirect_uri, className: 'form-control' }
{ doorkeeper_errors_for application, :redirect_uri } { doorkeeper_errors_for application, :redirect_uri }
<span class="help-block"> <span className="help-block">
{ t('doorkeeper.applications.help.redirect_uri') }. { t('doorkeeper.applications.help.redirect_uri') }.
</span> </span>
{ if Doorkeeper.configuration.native_redirect_uri } { if Doorkeeper.configuration.native_redirect_uri }
<span class="help-block"> <span className="help-block">
{ raw t('doorkeeper.applications.help.native_redirect_uri', native_redirect_uri: "<code>#{ Doorkeeper.configuration.native_redirect_uri }</code>") } { raw t('doorkeeper.applications.help.native_redirect_uri', native_redirect_uri: "<code>#{ Doorkeeper.configuration.native_redirect_uri }</code>") }
</span> </span>
{ end } { end }
</div> </div>
{ end } { end }
<div class="form-group"> <div className="form-group">
<div class="col-sm-offset-2 col-sm-10"> <div className="col-sm-offset-2 col-sm-10">
{ f.submit t('doorkeeper.applications.buttons.submit'), class: "btn btn-primary" } { f.submit t('doorkeeper.applications.buttons.submit'), className: "btn btn-primary" }
{ link_to t('doorkeeper.applications.buttons.cancel'), oauth_applications_path, :class => "button link-button red-button" } { link_to t('doorkeeper.applications.buttons.cancel'), oauth_applications_path, :className => "button link-button red-button" }
</div> </div>
</div> </div>
{ end } { end }

View file

@ -1,6 +1,6 @@
<div id="yield"> <div id="yield">
<div class="centerContent"> <div className="centerContent">
<div class="page-header"> <div className="page-header">
<h2>{ t('.title') }</h2> <h2>{ t('.title') }</h2>
</div> </div>

View file

@ -1,10 +1,10 @@
<div id="yield"> <div id="yield">
<div class="centerContent"> <div className="centerContent">
<div class="page-header"> <div className="page-header">
<h2>{ t('.title') }</h2> <h2>{ t('.title') }</h2>
</div> </div>
<table class="table table-striped"> <table className="table table-striped">
<thead> <thead>
<tr> <tr>
<th>{ t('.name') }</th> <th>{ t('.name') }</th>
@ -22,7 +22,7 @@
{ end } { end }
</tbody> </tbody>
</table> </table>
{ link_to t('.new'), new_oauth_application_path, class: 'button link-button' } { link_to t('.new'), new_oauth_application_path, className: 'button link-button' }
</div> </div>
</div> </div>
{ render 'script' } { render 'script' }

View file

@ -1,7 +1,7 @@
<div id="yield"> <div id="yield">
<div class="centerContent"> <div className="centerContent">
{ link_to t('doorkeeper.applications.buttons.back'), oauth_applications_path(), class: 'button link-button button-margin' } { link_to t('doorkeeper.applications.buttons.back'), oauth_applications_path(), className: 'button link-button button-margin' }
<div class="page-header"> <div className="page-header">
<h2>{ t('.title') }</h2> <h2>{ t('.title') }</h2>
</div> </div>

View file

@ -1,9 +1,9 @@
<div id="yield"> <div id="yield">
<div class="centerContent showApp"> <div className="centerContent showApp">
{ link_to t('doorkeeper.applications.buttons.back'), oauth_applications_path(), class: 'button link-button button-margin' } { link_to t('doorkeeper.applications.buttons.back'), oauth_applications_path(), className: 'button link-button button-margin' }
<div class="page-header"> <div className="page-header">
<h2>{ t('.title', name: @application.name) }</h2> <h2>{ t('.title', name: @application.name) }</h2>
</div> </div>
@ -23,15 +23,15 @@
<code>{ uri }</code> <code>{ uri }</code>
</td> </td>
<td> <td>
{ link_to t('doorkeeper.applications.buttons.authorize'), oauth_authorization_path(client_id: @application.uid, redirect_uri: uri, response_type: 'code'), class: 'button link-button', target: '_blank' } { link_to t('doorkeeper.applications.buttons.authorize'), oauth_authorization_path(client_id: @application.uid, redirect_uri: uri, response_type: 'code'), className: 'button link-button', target: '_blank' }
</td> </td>
</tr> </tr>
{ end } { end }
</table> </table>
<div class="inline-button">{ link_to t('doorkeeper.applications.buttons.edit'), edit_oauth_application_path(@application), class: 'button link-button' }</div> <div className="inline-button">{ link_to t('doorkeeper.applications.buttons.edit'), edit_oauth_application_path(@application), className: 'button link-button' }</div>
<div class="inline-button">{ render 'delete_form', application: @application, submit_btn_css: 'button red-button' }</div> <div className="inline-button">{ render 'delete_form', application: @application, submit_btn_css: 'button red-button' }</div>
</div> </div>
</div> </div>
{ render 'script' } { render 'script' }

View file

@ -1,6 +1,6 @@
<div id="yield"> <div id="yield">
<div class="centerContent"> <div className="centerContent">
<div class="page-header"> <div className="page-header">
<h2>{ t('doorkeeper.authorizations.error.title') }</h2> <h2>{ t('doorkeeper.authorizations.error.title') }</h2>
</div> </div>

View file

@ -1,19 +1,19 @@
<div id="yield"> <div id="yield">
<div class="centerContent"> <div className="centerContent">
<header class="page-header" role="banner"> <header className="page-header" role="banner">
<h1>{ t('.title') }</h1> <h1>{ t('.title') }</h1>
</header> </header>
<main role="main"> <main role="main">
<p class="h4"> <p className="h4">
{ raw t('.prompt', client_name: "<strong class=\"text-info\">#{ @pre_auth.client.name }</strong>") } { raw t('.prompt', client_name: "<strong className=\"text-info\">#{ @pre_auth.client.name }</strong>") }
</p> </p>
{ if @pre_auth.scopes.count > 0 } { if @pre_auth.scopes.count > 0 }
<div id="oauth-permissions"> <div id="oauth-permissions">
<p>{ t('.able_to') }:</p> <p>{ t('.able_to') }:</p>
<ul class="text-info"> <ul className="text-info">
{ @pre_auth.scopes.each do |scope| } { @pre_auth.scopes.each do |scope| }
<li>{ t scope, scope: [:doorkeeper, :scopes] }</li> <li>{ t scope, scope: [:doorkeeper, :scopes] }</li>
{ end } { end }
@ -21,25 +21,25 @@
</div> </div>
{ end } { end }
<div class="actions"> <div className="actions">
<div class="inline-button button-margin-top"> <div className="inline-button button-margin-top">
{ form_tag oauth_authorization_path, method: :post do } { form_tag oauth_authorization_path, method: :post do }
{ hidden_field_tag :client_id, @pre_auth.client.uid } { hidden_field_tag :client_id, @pre_auth.client.uid }
{ hidden_field_tag :redirect_uri, @pre_auth.redirect_uri } { hidden_field_tag :redirect_uri, @pre_auth.redirect_uri }
{ hidden_field_tag :state, @pre_auth.state } { hidden_field_tag :state, @pre_auth.state }
{ hidden_field_tag :response_type, @pre_auth.response_type } { hidden_field_tag :response_type, @pre_auth.response_type }
{ hidden_field_tag :scope, @pre_auth.scope } { hidden_field_tag :scope, @pre_auth.scope }
{ submit_tag t('doorkeeper.authorizations.buttons.authorize'), class: "button" } { submit_tag t('doorkeeper.authorizations.buttons.authorize'), className: "button" }
{ end } { end }
</div> </div>
<div class="inline-button button-margin-top"> <div className="inline-button button-margin-top">
{ form_tag oauth_authorization_path, method: :delete do } { form_tag oauth_authorization_path, method: :delete do }
{ hidden_field_tag :client_id, @pre_auth.client.uid } { hidden_field_tag :client_id, @pre_auth.client.uid }
{ hidden_field_tag :redirect_uri, @pre_auth.redirect_uri } { hidden_field_tag :redirect_uri, @pre_auth.redirect_uri }
{ hidden_field_tag :state, @pre_auth.state } { hidden_field_tag :state, @pre_auth.state }
{ hidden_field_tag :response_type, @pre_auth.response_type } { hidden_field_tag :response_type, @pre_auth.response_type }
{ hidden_field_tag :scope, @pre_auth.scope } { hidden_field_tag :scope, @pre_auth.scope }
{ submit_tag t('doorkeeper.authorizations.buttons.deny'), class: "button red-button" } { submit_tag t('doorkeeper.authorizations.buttons.deny'), className: "button red-button" }
{ end } { end }
</div> </div>
</div> </div>

View file

@ -1,6 +1,6 @@
<div id="yield"> <div id="yield">
<div class="centerContent"> <div className="centerContent">
<header class="page-header"> <header className="page-header">
<h2>{ t('.title') }</h2> <h2>{ t('.title') }</h2>
</header> </header>

View file

@ -1,5 +1,5 @@
{- submit_btn_css ||= 'button red-button' } {- submit_btn_css ||= 'button red-button' }
{ form_tag oauth_authorized_application_path(application) do } { form_tag oauth_authorized_application_path(application) do }
<input type="hidden" name="_method" value="delete"> <input type="hidden" name="_method" value="delete">
{ submit_tag t('doorkeeper.authorized_applications.buttons.revoke'), onclick: "return confirm('#{ t('doorkeeper.authorized_applications.confirmations.revoke') }')", class: submit_btn_css } { submit_tag t('doorkeeper.authorized_applications.buttons.revoke'), onclick: "return confirm('#{ t('doorkeeper.authorized_applications.confirmations.revoke') }')", className: submit_btn_css }
{ end } { end }

View file

@ -1,6 +1,6 @@
<div id="yield"> <div id="yield">
<div class="centerContent"> <div className="centerContent">
<header class="page-header"> <header className="page-header">
<h2>{ t('doorkeeper.authorized_applications.index.title') }</h2> <h2>{ t('doorkeeper.authorized_applications.index.title') }</h2>
</header> </header>
@ -11,7 +11,7 @@
If you're a developer interested in building an app for Metamaps, check out <a href="https://metamaps.cc/api" target="_blank">the API docs</a>. If you're a developer interested in building an app for Metamaps, check out <a href="https://metamaps.cc/api" target="_blank">the API docs</a>.
</div><br /> </div><br />
{ if @applications.count > 0 } { if @applications.count > 0 }
<table class="table table-striped"> <table className="table table-striped">
<thead> <thead>
<tr> <tr>
<th>{ t('doorkeeper.authorized_applications.index.application') }</th> <th>{ t('doorkeeper.authorized_applications.index.application') }</th>

View file

@ -16,7 +16,7 @@
{ csrf_meta_tags } { csrf_meta_tags }
<meta name="viewport" content="width=device-width, user-scalable=no"> <meta name="viewport" content="width=device-width, user-scalable=no">
{ if controller.class.name == 'MapsController' && @map } { if controller.className.name == 'MapsController' && @map }
<meta property="og:title" content="{ @map.name }" /> <meta property="og:title" content="{ @map.name }" />
<meta property="og:type" content="website" /> <meta property="og:type" content="website" />
<meta property="og:image" content="{ @map.screenshot_url }" /> <meta property="og:image" content="{ @map.screenshot_url }" />

View file

@ -7,7 +7,7 @@
<a id="lightbox_close" href="#"></a> <a id="lightbox_close" href="#"></a>
<div id="lightbox_content"> <div id="lightbox_content">
<div class="lightboxContent" id="about"> <div className="lightboxContent" id="about">
<h3>About Metamaps.cc</h3> <h3>About Metamaps.cc</h3>
<div id="aboutParms"> <div id="aboutParms">
<div id="leftAboutParms"> <div id="leftAboutParms">
@ -23,7 +23,7 @@
<p>{ METAMAPS_BUILD }</p> <p>{ METAMAPS_BUILD }</p>
<p>{ METAMAPS_LAST_UPDATED }</p> <p>{ METAMAPS_LAST_UPDATED }</p>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<p>Metamaps.cc is a free and open source web platform that supports real-time sense-making and distributed collaboration between individuals, communities and organizations.</p> <p>Metamaps.cc is a free and open source web platform that supports real-time sense-making and distributed collaboration between individuals, communities and organizations.</p>
@ -32,42 +32,42 @@
<p>Metamaps.cc is created and maintained by a distributed community of contributors passionate about the evolution of collaboration, alternative forms of value creation and increase of collective intelligence through the lens of the open culture and the peer-to-peer revolution.</p> <p>Metamaps.cc is created and maintained by a distributed community of contributors passionate about the evolution of collaboration, alternative forms of value creation and increase of collective intelligence through the lens of the open culture and the peer-to-peer revolution.</p>
<ul class="lightbox_links"> <ul className="lightbox_links">
<li> <li>
<a class="icon_twitter" href="https://twitter.com/metamapps" target="_blank"> <a className="icon_twitter" href="https://twitter.com/metamapps" target="_blank">
<div class="lightboxAboutIcon"></div> <div className="lightboxAboutIcon"></div>
@metamapps @metamapps
</a> </a>
</li> </li>
<li> <li>
<a class="icon_community" href="https://www.hylo.com/c/metamaps/join/mice-late-hit-two-shown" target="_blank"> <a className="icon_community" href="https://www.hylo.com/c/metamaps/join/mice-late-hit-two-shown" target="_blank">
<div class="lightboxAboutIcon"></div> <div className="lightboxAboutIcon"></div>
community community
</a> </a>
</li> </li>
<li> <li>
<a class="icon_source_code" href="https://github.com/metamaps/metamaps" target="_blank"> <a className="icon_source_code" href="https://github.com/metamaps/metamaps" target="_blank">
<div class="lightboxAboutIcon"></div> <div className="lightboxAboutIcon"></div>
source code source code
</a> </a>
</li> </li>
<li> <li>
<a class="icon_howtos" href="https://docs.metamaps.cc" target="_blank"> <a className="icon_howtos" href="https://docs.metamaps.cc" target="_blank">
<div class="lightboxAboutIcon"></div> <div className="lightboxAboutIcon"></div>
howtos howtos
</a> </a>
</li> </li>
<li> <li>
<a class="icon_terms" href="https://metamaps.cc/maps/331" target="_blank"> <a className="icon_terms" href="https://metamaps.cc/maps/331" target="_blank">
<div class="lightboxAboutIcon"></div> <div className="lightboxAboutIcon"></div>
terms terms
</a> </a>
</li> </li>
</ul> </ul>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<div class="lightboxContent" id="noIE"> <div className="lightboxContent" id="noIE">
<h3>OOPS! <br> YOUR BROWSER IS NOT SUPPORTED.</h3> <h3>OOPS! <br> YOUR BROWSER IS NOT SUPPORTED.</h3>
<p id="noIEsubheading">To view this experience, please upgrade to the latest one of these browsers:</p> <p id="noIEsubheading">To view this experience, please upgrade to the latest one of these browsers:</p>
<a id="chromeIcon" href="https://www.google.com/chrome/browser/" target="_blank">Chrome</a> <a id="chromeIcon" href="https://www.google.com/chrome/browser/" target="_blank">Chrome</a>
@ -77,35 +77,35 @@
</div> </div>
<div class="lightboxContent" id="tutorial"> <div className="lightboxContent" id="tutorial">
<h3>Tutorial</h3> <h3>Tutorial</h3>
<iframe src="//player.vimeo.com/video/88334167?title=0&amp;byline=0&amp;portrait=0" width="510" height="319" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe> <iframe src="//player.vimeo.com/video/88334167?title=0&amp;byline=0&amp;portrait=0" width="510" height="319" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>
</div> </div>
<div class="lightboxContent" id="cheatsheet"> <div className="lightboxContent" id="cheatsheet">
{ render :partial => 'shared/cheatsheet' } { render :partial => 'shared/cheatsheet' }
</div> </div>
{ if current_user } { if current_user }
<div class="lightboxContent" id="invite"> <div className="lightboxContent" id="invite">
<h3>SHARE INVITE</h3> <h3>SHARE INVITE</h3>
<div class="leaveSpace"></div> <div className="leaveSpace"></div>
<p>The Metamaps platform is currently in an invite-only beta with the express purpose of creating a high value knowledge ecosystem, a diverse community of contributors and a culture of collaboration and curiosity.</p> <p>The Metamaps platform is currently in an invite-only beta with the express purpose of creating a high value knowledge ecosystem, a diverse community of contributors and a culture of collaboration and curiosity.</p>
<p>As a valued beta tester, you have the ability to invite your peers, colleagues and collaborators onto the platform.</p> <p>As a valued beta tester, you have the ability to invite your peers, colleagues and collaborators onto the platform.</p>
<p>Below is a personal invite link containing your unique access code, which can be used multiple times.</p> <p>Below is a personal invite link containing your unique access code, which can be used multiple times.</p>
<div id="joinCodesBox"> <div id="joinCodesBox">
<p class="joinCodes">{ invite_link() } <p className="joinCodes">{ invite_link() }
<button class="button" onclick="Metamaps.GlobalUI.shareInvite('{ @invite_link }');">COPY INVITE LINK!</button> <button className="button" onclick="Metamaps.GlobalUI.shareInvite('{ @invite_link }');">COPY INVITE LINK!</button>
</div> </div>
</div> </div>
<div class="lightboxContent" id="forkmap"> <div className="lightboxContent" id="forkmap">
{ render :partial => 'shared/forkmap' } { render :partial => 'shared/forkmap' }
</div> </div>
<div class="lightboxContent" id="switchMetacodes"> <div className="lightboxContent" id="switchMetacodes">
{ render :partial => 'shared/switchmetacodes' } { render :partial => 'shared/switchmetacodes' }
</div> </div>
{ end } { end }

View file

@ -3,48 +3,48 @@
# templates for the upper right autocomplete results # templates for the upper right autocomplete results
#} #}
<div class="templates"> <div className="templates">
<script type="text/template" id="mapInfoBoxTemplate"> <script type="text/template" id="mapInfoBoxTemplate">
<div class="requestTitle">Click here to name this map</div> <div className="requestTitle">Click here to name this map</div>
<div class="mapInfoName" id="mapInfoName">{{{name}}}</div> <div className="mapInfoName" id="mapInfoName">{{{name}}}</div>
<div class="mapInfoStat"> <div className="mapInfoStat">
<div class="infoStatIcon mapContributors hoverForTip"> <div className="infoStatIcon mapContributors hoverForTip">
<img id="mapContribs" class="{{contributors_class}}" <img id="mapContribs" className="{{contributors_className}}"
width="25" height="25" src="{{contributor_image}}" /> width="25" height="25" src="{{contributor_image}}" />
<span class="count">{{contributor_count}}</span> <span className="count">{{contributor_count}}</span>
<div class="tip">{{{contributor_list}}}</div> <div className="tip">{{{contributor_list}}}</div>
</div> </div>
<div class="infoStatIcon mapTopics"> <div className="infoStatIcon mapTopics">
{{topic_count}} {{topic_count}}
</div> </div>
<div class="infoStatIcon mapSynapses"> <div className="infoStatIcon mapSynapses">
{{synapse_count}} {{synapse_count}}
</div> </div>
<div class="infoStatIcon mapPermission {{permission}} hoverForTip"> <div className="infoStatIcon mapPermission {{permission}} hoverForTip">
{{{map_creator_tip}}} {{{map_creator_tip}}}
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<div class="mapInfoDesc" id="mapInfoDesc"> <div className="mapInfoDesc" id="mapInfoDesc">
{{{desc}}} {{{desc}}}
</div> </div>
<div class="mapInfoMeta"> <div className="mapInfoMeta">
<p class="mapCreatedAt"><span>Created by:</span> {{user_name}} on {{created_at}}</p> <p className="mapCreatedAt"><span>Created by:</span> {{user_name}} on {{created_at}}</p>
<p class="mapEditedAt"><span>Last edited:</span> {{updated_at}}</p> <p className="mapEditedAt"><span>Last edited:</span> {{updated_at}}</p>
<div class="mapInfoButtonsWrapper"> <div className="mapInfoButtonsWrapper">
<div class="mapInfoThumbnail"> <div className="mapInfoThumbnail">
<div class="thumbnail"></div> <div className="thumbnail"></div>
<div class="tooltip">Update Thumbnail</div> <div className="tooltip">Update Thumbnail</div>
<span>Thumb</span> <span>Thumb</span>
</div> </div>
<div class="mapInfoDelete"> <div className="mapInfoDelete">
<div class="deleteMap"></div> <div className="deleteMap"></div>
<span>Delete</span> <span>Delete</span>
</div> </div>
<div class="mapInfoShare"> <div className="mapInfoShare">
<div class="mapInfoShareIcon"></div> <div className="mapInfoShareIcon"></div>
<span>Share</span> <span>Share</span>
</div> </div>
</div> </div>
@ -52,133 +52,133 @@
</script> </script>
<script type="text/template" id="topicSearchTemplate"> <script type="text/template" id="topicSearchTemplate">
<div class="result{{rtype}}"> <div className="result{{rtype}}">
<div class="topicMetacode searchResIconWrapper"> <div className="topicMetacode searchResIconWrapper">
<img src="{{typeImageURL}}" class="topicIcon" /> <img src="{{typeImageURL}}" className="topicIcon" />
<div class="metacodeTip">{{type}}</div> <div className="metacodeTip">{{type}}</div>
</div> </div>
<div class="resultText"> <div className="resultText">
<p class="resultTitle">{{label}}</p> <p className="resultTitle">{{label}}</p>
<p class="resultDesc">{{description}}</p> <p className="resultDesc">{{description}}</p>
</div> </div>
<div class="autoOptions"> <div className="autoOptions">
<button class="addToMap hoverForTip" onclick="return Metamaps.Topic.getTopicFromSearch(event, {{id}})"> <button className="addToMap hoverForTip" onclick="return Metamaps.Topic.getTopicFromSearch(event, {{id}})">
<span class="tip">add to map</span> <span className="tip">add to map</span>
</button> </button>
<div class="mapCount"> <div className="mapCount">
{{mapCount}} {{mapCount}}
</div> </div>
<div class="synapseCount"> <div className="synapseCount">
{{synapseCount}} {{synapseCount}}
</div> </div>
<div class="topicOriginatorIcon hoverForTip"> <div className="topicOriginatorIcon hoverForTip">
<img width="18" height="18" src="{{originatorImage}}"> <img width="18" height="18" src="{{originatorImage}}">
<span class="tip topicOriginator">{{originator}}</span> <span className="tip topicOriginator">{{originator}}</span>
</div> </div>
<div class="topicPermission {{permission}}"> <div className="topicPermission {{permission}}">
</div> </div>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
</script> </script>
<script type="text/template" id="mapSearchTemplate"> <script type="text/template" id="mapSearchTemplate">
<div class="result{{rtype}}"> <div className="result{{rtype}}">
<div class="searchResIconWrapper"> <div className="searchResIconWrapper">
<img class="icon" src="/images/metamap36c.png"> <img className="icon" src="/images/metamap36c.png">
</div> </div>
<div class="resultText"> <div className="resultText">
<p class="resultTitle">{{label}}</p> <p className="resultTitle">{{label}}</p>
<p class="resultDesc">{{description}}</p> <p className="resultDesc">{{description}}</p>
</div> </div>
<div class="autoOptions"> <div className="autoOptions">
<div class="topicCount"> <div className="topicCount">
{{topicCount}} {{topicCount}}
</div> </div>
<div class="synapseCount"> <div className="synapseCount">
{{synapseCount}} {{synapseCount}}
</div> </div>
<div class="mapContributorsIcon hoverForTip"> <div className="mapContributorsIcon hoverForTip">
<img id="mapContribs" width="25" height="25" src="{{mapContributorImage}}" /> <img id="mapContribs" width="25" height="25" src="{{mapContributorImage}}" />
<div class="tip"> <div className="tip">
<ul> <ul>
{{{contributorTip}}} {{{contributorTip}}}
</ul> </ul>
</div> </div>
<span>{{contributorCount}}</span> <span>{{contributorCount}}</span>
</div> </div>
<div class="mapPermission {{permission}}"> <div className="mapPermission {{permission}}">
</div> </div>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
</script> </script>
<script type="text/template" id="mapperSearchTemplate"> <script type="text/template" id="mapperSearchTemplate">
<div class="result{{rtype}}"> <div className="result{{rtype}}">
<div class="searchResIconWrapper"> <div className="searchResIconWrapper">
<img class="icon" width="32" height="32" src="{{profile}}"> <img className="icon" width="32" height="32" src="{{profile}}">
</div> </div>
<div class="resultText"> <div className="resultText">
<p class="resultTitle">{{label}}</p> <p className="resultTitle">{{label}}</p>
</div> </div>
<div class="autoOptions"> <div className="autoOptions">
<div class="mapperCreated"> <div className="mapperCreated">
<p>Mapping since: {{created_at}}</p> <p>Mapping since: {{created_at}}</p>
</div> </div>
<div class="mapperGeneration"> <div className="mapperGeneration">
<p>Generation: {{generation}}</p> <p>Generation: {{generation}}</p>
</div> </div>
<div class="mapCount"> <div className="mapCount">
{{mapCount}} {{mapCount}}
</div> </div>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
</script> </script>
<script type="text/template" id="collaboratorSearchTemplate"> <script type="text/template" id="collaboratorSearchTemplate">
<div class="collabResult"> <div className="collabResult">
<div class="collabIconWrapper"> <div className="collabIconWrapper">
<img class="icon" width="25" height="25" src="{{profile}}"> <img className="icon" width="25" height="25" src="{{profile}}">
</div> </div>
<div class="collabNameWrapper"> <div className="collabNameWrapper">
<p class="collabName">{{label}}</p> <p className="collabName">{{label}}</p>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
</script> </script>
<script type="text/template" id="synapseAutocompleteTemplate"> <script type="text/template" id="synapseAutocompleteTemplate">
<div class="result{{rtype}}"> <div className="result{{rtype}}">
<p class="autocompleteSection synapseDesc">{{label}}</p> <p className="autocompleteSection synapseDesc">{{label}}</p>
<div class="synapseMetadata"> <div className="synapseMetadata">
<div class="synapseOriginatorIcon hoverForTip"> <div className="synapseOriginatorIcon hoverForTip">
<img width="24" height="24" src="{{originatorImage}}" /> <img width="24" height="24" src="{{originatorImage}}" />
<span class="tooltips synapseOriginator">{{originator}}</span> <span className="tooltips synapseOriginator">{{originator}}</span>
</div> </div>
<div class="synapsePermission {{permission}}"></div> <div className="synapsePermission {{permission}}"></div>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
</script> </script>
<script type="text/template" id="topicAutocompleteTemplate"> <script type="text/template" id="topicAutocompleteTemplate">
<div> <div>
<img class="autocompleteSection topicType" width="24" height="24" <img className="autocompleteSection topicType" width="24" height="24"
src="{{typeImageURL}}" alt="{{type}}" title="{{type}}" /> src="{{typeImageURL}}" alt="{{type}}" title="{{type}}" />
<p class="autocompleteSection topicTitle">{{label}}</p> <p className="autocompleteSection topicTitle">{{label}}</p>
<div class="expandTopicMetadata"></div> <div className="expandTopicMetadata"></div>
<div class="topicMetadata"> <div className="topicMetadata">
<div class="topicNumMaps">{{mapCount}}</div> <div className="topicNumMaps">{{mapCount}}</div>
<div class="topicNumSynapses">{{synapseCount}}</div> <div className="topicNumSynapses">{{synapseCount}}</div>
<div class="topicOriginatorIcon hoverForTip"> <div className="topicOriginatorIcon hoverForTip">
<img width="24" height="24" src="{{originatorImage}}" /> <img width="24" height="24" src="{{originatorImage}}" />
<span class="tooltips topicOriginator">{{originator}}</span> <span className="tooltips topicOriginator">{{originator}}</span>
</div> </div>
<div class="topicPermission {{permission}}"></div> <div className="topicPermission {{permission}}"></div>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
</script> </script>
</div> </div>

View file

@ -6,8 +6,8 @@
#} #}
{ render :partial => 'layouts/head' } { render :partial => 'layouts/head' }
<body class="{ current_user ? "authenticated" : "unauthenticated" } controller-{ controller_name } action-{ action_name }"> <body className="{ current_user ? "authenticated" : "unauthenticated" } controller-{ controller_name } action-{ action_name }">
<div class="main" id="react-app"></div> <div className="main" id="react-app"></div>
{ yield } { yield }
{ if current_user } { if current_user }
{ # for creating and pulling in topics and synapses } { # for creating and pulling in topics and synapses }

View file

@ -1,25 +1,25 @@
{ @metacodes = user_metacodes() } { @metacodes = user_metacodes() }
{ form_for Topic.new, url: topics_url, remote: true do |form| } { form_for Topic.new, url: topics_url, remote: true do |form| }
<div class="openMetacodeSwitcher openLightbox" data-open="switchMetacodes"> <div className="openMetacodeSwitcher openLightbox" data-open="switchMetacodes">
<div class="tooltipsAbove">Switch Metacodes</div> <div className="tooltipsAbove">Switch Metacodes</div>
</div> </div>
<div class="pinCarousel"> <div className="pinCarousel">
<div class="tooltipsAbove helpPin">Pin Open</div> <div className="tooltipsAbove helpPin">Pin Open</div>
<div class="tooltipsAbove helpUnpin">Unpin</div> <div className="tooltipsAbove helpUnpin">Unpin</div>
</div> </div>
<div id="metacodeImg"> <div id="metacodeImg">
{ @metacodes.each do |metacode| } { @metacodes.each do |metacode| }
<img class="cloudcarousel" width="40" height="40" src="{ asset_path metacode.icon }" alt="{ metacode.name }" title="{ metacode.name }" data-id="{ metacode.id }" /> <img className="cloudcarousel" width="40" height="40" src="{ asset_path metacode.icon }" alt="{ metacode.name }" title="{ metacode.name }" data-id="{ metacode.id }" />
{ end } { end }
</div> </div>
{ form.text_field :name, :maxlength => 140, :placeholder => "title..." } { form.text_field :name, :maxlength => 140, :placeholder => "title..." }
<div id="metacodeImgTitle"></div> <div id="metacodeImgTitle"></div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
<script> <script>
{ @metacodes.each do |metacode| } { @metacodes.each do |metacode| }

View file

@ -11,79 +11,79 @@
</div> </div>
{ end } { end }
<div class="field"> <div className="field">
{ f.label :name } { f.label :name }
{ f.text_field :name } { f.text_field :name }
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<div class="field"> <div className="field">
{ f.label :desc, "Description" } { f.label :desc, "Description" }
{ f.text_area :desc, :cols => "40", :rows => "4" } { f.text_area :desc, :cols => "40", :rows => "4" }
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<br /> <br />
<p>Choose Metacodes</p> <p>Choose Metacodes</p>
<div class="allMetacodes"> <div className="allMetacodes">
<span id="showAll" onclick="Metamaps.Admin.selectAll();">Select All</span> <span id="showAll" onclick="Metamaps.Admin.selectAll();">Select All</span>
<span id="hideAll" onclick="Metamaps.Admin.deselectAll();">Unselect All</span> <span id="hideAll" onclick="Metamaps.Admin.deselectAll();">Unselect All</span>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
<div class="editMetacodes"> <div className="editMetacodes">
<ul id="filters-one"> <ul id="filters-one">
{ $i = 0 } { $i = 0 }
{ @m = Metacode.order("name").all } { @m = Metacode.order("name").all }
{ while $i < (Metacode.all.length / 4) do } { while $i < (Metacode.all.length / 4) do }
<li id="{ @m[$i].id }" { if not @m[$i].in_metacode_set(@metacode_set) }class="toggledOff"{ end } <li id="{ @m[$i].id }" { if not @m[$i].in_metacode_set(@metacode_set) }className="toggledOff"{ end }
onclick="Metamaps.Admin.liClickHandler.call(this);"> onclick="Metamaps.Admin.liClickHandler.call(this);">
<img src="{ asset_path @m[$i].icon }" alt="{ @m[$i].name }" /> <img src="{ asset_path @m[$i].icon }" alt="{ @m[$i].name }" />
<p>{ @m[$i].name.downcase }</p> <p>{ @m[$i].name.downcase }</p>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</li> </li>
{ $i += 1 } { $i += 1 }
{ end } { end }
</ul> </ul>
<ul id="filters-two"> <ul id="filters-two">
{ while $i < (Metacode.all.length / 4 * 2) do } { while $i < (Metacode.all.length / 4 * 2) do }
<li id="{ @m[$i].id }" { if not @m[$i].in_metacode_set(@metacode_set) }class="toggledOff"{ end } <li id="{ @m[$i].id }" { if not @m[$i].in_metacode_set(@metacode_set) }className="toggledOff"{ end }
onclick="Metamaps.Admin.liClickHandler.call(this);"> onclick="Metamaps.Admin.liClickHandler.call(this);">
<img src="{ asset_path @m[$i].icon }" alt="{ @m[$i].name }" /> <img src="{ asset_path @m[$i].icon }" alt="{ @m[$i].name }" />
<p>{ @m[$i].name.downcase }</p> <p>{ @m[$i].name.downcase }</p>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</li> </li>
{ $i += 1 } { $i += 1 }
{ end } { end }
</ul> </ul>
<ul id="filters-three"> <ul id="filters-three">
{ while $i < (Metacode.all.length / 4 * 3) do } { while $i < (Metacode.all.length / 4 * 3) do }
<li id="{ @m[$i].id }" { if not @m[$i].in_metacode_set(@metacode_set) }class="toggledOff"{ end } <li id="{ @m[$i].id }" { if not @m[$i].in_metacode_set(@metacode_set) }className="toggledOff"{ end }
onclick="Metamaps.Admin.liClickHandler.call(this);"> onclick="Metamaps.Admin.liClickHandler.call(this);">
<img src="{ asset_path @m[$i].icon }" alt="{ @m[$i].name }" /> <img src="{ asset_path @m[$i].icon }" alt="{ @m[$i].name }" />
<p>{ @m[$i].name.downcase }</p> <p>{ @m[$i].name.downcase }</p>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</li> </li>
{ $i += 1 } { $i += 1 }
{ end } { end }
</ul> </ul>
<ul id="filters-four"> <ul id="filters-four">
{ while $i < Metacode.all.length do } { while $i < Metacode.all.length do }
<li id="{ @m[$i].id }" { if not @m[$i].in_metacode_set(@metacode_set) }class="toggledOff"{ end } <li id="{ @m[$i].id }" { if not @m[$i].in_metacode_set(@metacode_set) }className="toggledOff"{ end }
onclick="Metamaps.Admin.liClickHandler.call(this);"> onclick="Metamaps.Admin.liClickHandler.call(this);">
<img src="{ asset_path @m[$i].icon }" alt="{ @m[$i].name }" /> <img src="{ asset_path @m[$i].icon }" alt="{ @m[$i].name }" />
<p>{ @m[$i].name.downcase }</p> <p>{ @m[$i].name.downcase }</p>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</li> </li>
{ $i += 1 } { $i += 1 }
{ end } { end }
</ul> </ul>
</div> </div>
{ hidden_field(:metacodes, :value, {:value => 0}) } { hidden_field(:metacodes, :value, {:value => 0}) }
<div class="clearfloat"></div> <div className="clearfloat"></div>
<div class="actions"> <div className="actions">
{ link_to 'Cancel', metacode_sets_path, { link_to 'Cancel', metacode_sets_path,
{ :class => 'button' } } { :className => 'button' } }
{ f.submit :class => 'add', :onclick => "return Metamaps.Admin.validate();" } { f.submit :className => 'add', :onclick => "return Metamaps.Admin.validate();" }
</div> </div>
{ end } { end }

View file

@ -1,5 +1,5 @@
<div id="yield"> <div id="yield">
<div class='centerContent'> <div className='centerContent'>
{ render 'form' } { render 'form' }
</div> </div>
</div> </div>

View file

@ -1,10 +1,10 @@
<div id="yield"> <div id="yield">
<div class='centerContent'> <div className='centerContent'>
<br /> <br />
<table> <table>
<tr> <tr>
<th>Name</th> <th>Name</th>
<th class='metacodeSetsDescription'>Description</th> <th className='metacodeSetsDescription'>Description</th>
<th>Metacodes</th> <th>Metacodes</th>
</tr> </tr>
@ -19,15 +19,15 @@
metacode_set, method: :delete, metacode_set, method: :delete,
data: { confirm: 'Are you sure?' } } data: { confirm: 'Are you sure?' } }
</td> </td>
<td class='metacodeSetDesc'>{ metacode_set.desc }</td> <td className='metacodeSetDesc'>{ metacode_set.desc }</td>
<td> <td>
{ metacode_set.metacodes.each_with_index do |metacode, index| } { metacode_set.metacodes.each_with_index do |metacode, index| }
<img class='metacodeSetImage' src='{ asset_path metacode.icon }' /> <img className='metacodeSetImage' src='{ asset_path metacode.icon }' />
{ if (index+1)%4 == 0 } { if (index+1)%4 == 0 }
<div class='clearfloat'></div> <div className='clearfloat'></div>
{ end } { end }
{ end } { end }
<div class='clearfloat'></div> <div className='clearfloat'></div>
</td> </td>
</tr> </tr>
{ end } { end }

View file

@ -1,5 +1,5 @@
<div id="yield"> <div id="yield">
<div class='centerContent'> <div className='centerContent'>
{ render 'form' } { render 'form' }
</div> </div>
</div> </div>

View file

@ -10,18 +10,18 @@
</div> </div>
{ end } { end }
<div class="field"> <div className="field">
{ f.label :name } { f.label :name }
{ f.text_field :name } { f.text_field :name }
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
{ unless @metacode.new_record? } { unless @metacode.new_record? }
<div class="field"> <div className="field">
{ f.label 'Current Icon' } { f.label 'Current Icon' }
{ image_tag @metacode.icon, width: 96 } { image_tag @metacode.icon, width: 96 }
</div> </div>
{ end } { end }
<div class="field"> <div className="field">
{ if @metacode.new_record? } { if @metacode.new_record? }
{ f.label 'Icon' } { f.label 'Icon' }
{ else } { else }
@ -29,15 +29,15 @@
{ end } { end }
{ f.hidden_field :manual_icon, value: nil } { f.hidden_field :manual_icon, value: nil }
{ f.file_field :aws_icon } { f.file_field :aws_icon }
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<div class="field"> <div className="field">
{ f.label :color, "Color (hex with # sign)" } { f.label :color, "Color (hex with # sign)" }
{ f.text_field :color } { f.text_field :color }
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<div class="actions"> <div className="actions">
{ link_to 'Cancel', metacodes_path, { :class => 'button' } } { link_to 'Cancel', metacodes_path, { :className => 'button' } }
{ f.submit :class => 'add' } { f.submit :className => 'add' }
</div> </div>
{ end } { end }

View file

@ -1,5 +1,5 @@
<div id="yield"> <div id="yield">
<div class='centerContent'> <div className='centerContent'>
{ render 'form' } { render 'form' }
</div> </div>
</div> </div>

View file

@ -1,5 +1,5 @@
<div id="yield"> <div id="yield">
<div class='centerContent'> <div className='centerContent'>
<br /> <br />
<table> <table>
<tr> <tr>
@ -13,9 +13,9 @@
{ @metacodes.each do |metacode| } { @metacodes.each do |metacode| }
<tr> <tr>
<td>{ metacode.name }</td> <td>{ metacode.name }</td>
<td class="iconURL">{ metacode.icon }</td> <td className="iconURL">{ metacode.icon }</td>
{ if metacode.color } { if metacode.color }
<td class="iconColor" style="background-color: { metacode.color }"> <td className="iconColor" style="background-color: { metacode.color }">
{ metacode.color } { metacode.color }
</td> </td>
{ else } { else }

View file

@ -1,5 +1,5 @@
<div id="yield"> <div id="yield">
<div class='centerContent'> <div className='centerContent'>
{ render 'form' } { render 'form' }
</div> </div>
</div> </div>

View file

@ -2,68 +2,68 @@
{ content_for :mobile_title, 'Notifications' } { content_for :mobile_title, 'Notifications' }
<div id="yield"> <div id="yield">
<div class="centerContent notificationsPage"> <div className="centerContent notificationsPage">
<header class="page-header"> <header className="page-header">
<h2 class="title">Notifications</h4> <h2 className="title">Notifications</h4>
</header> </header>
<ul class="notifications"> <ul className="notifications">
{ blacklist = [MAP_ACCESS_REQUEST, MAP_ACCESS_APPROVED, MAP_INVITE_TO_EDIT] } { blacklist = [MAP_ACCESS_REQUEST, MAP_ACCESS_APPROVED, MAP_INVITE_TO_EDIT] }
{ notifications = @notifications.to_a.delete_if{|n| blacklist.include?(n.notification_code) && (n.notified_object.nil? || n.notified_object.map.nil?) }} { notifications = @notifications.to_a.delete_if{|n| blacklist.include?(n.notification_code) && (n.notified_object.nil? || n.notified_object.map.nil?) }}
{ notifications.each do |notification| } { notifications.each do |notification| }
{ receipt = @receipts.find_by(notification_id: notification.id) } { receipt = @receipts.find_by(notification_id: notification.id) }
<li class="notification { receipt.is_read? ? 'read' : 'unread' }" id="notification-{ notification.id }"> <li className="notification { receipt.is_read? ? 'read' : 'unread' }" id="notification-{ notification.id }">
{ link_to notification_path(notification.id) do } { link_to notification_path(notification.id) do }
<div class="notification-actor"> <div className="notification-actor">
{ image_tag notification.sender.image(:thirtytwo) } { image_tag notification.sender.image(:thirtytwo) }
</div> </div>
<div class="notification-body"> <div className="notification-body">
<div class="in-bold">{ notification.sender.name }</div> <div className="in-bold">{ notification.sender.name }</div>
{ {
case notification.notification_code case notification.notification_code
when MAP_ACCESS_APPROVED } when MAP_ACCESS_APPROVED }
{ map = notification.notified_object.map } { map = notification.notified_object.map }
granted your request to edit map <span class="in-bold">{ map.name }</span> granted your request to edit map <span className="in-bold">{ map.name }</span>
{ when MAP_ACCESS_REQUEST } { when MAP_ACCESS_REQUEST }
{ map = notification.notified_object.map } { map = notification.notified_object.map }
wants permission to map with you on <span class="in-bold">{ map.name }</span> wants permission to map with you on <span className="in-bold">{ map.name }</span>
{ if !notification.notified_object.answered } { if !notification.notified_object.answered }
&nbsp;&nbsp;<div class="action">Offer a response</div> &nbsp;&nbsp;<div className="action">Offer a response</div>
{ end } { end }
{ when MAP_INVITE_TO_EDIT } { when MAP_INVITE_TO_EDIT }
{ map = notification.notified_object.map } { map = notification.notified_object.map }
gave you edit access to map <span class="in-bold">{ map.name }</span> gave you edit access to map <span className="in-bold">{ map.name }</span>
{ when TOPIC_ADDED_TO_MAP } { when TOPIC_ADDED_TO_MAP }
{ topic = notification.notified_object.eventable { topic = notification.notified_object.eventable
map = notification.notified_object.map } map = notification.notified_object.map }
added topic <span class="in-bold">{ topic.name }</span> to map <span class="in-bold">{ map.name }</span> added topic <span className="in-bold">{ topic.name }</span> to map <span className="in-bold">{ map.name }</span>
{ when TOPIC_CONNECTED_1 } { when TOPIC_CONNECTED_1 }
{ topic1 = notification.notified_object&.topic1 } { topic1 = notification.notified_object&.topic1 }
{ topic2 = notification.notified_object&.topic2 } { topic2 = notification.notified_object&.topic2 }
connected <span class="in-bold">{ topic1&.name }</span> to <span class="in-bold">{ topic2&.name }</span> connected <span className="in-bold">{ topic1&.name }</span> to <span className="in-bold">{ topic2&.name }</span>
{ when TOPIC_CONNECTED_2 } { when TOPIC_CONNECTED_2 }
{ topic1 = notification.notified_object&.topic1 } { topic1 = notification.notified_object&.topic1 }
{ topic2 = notification.notified_object&.topic2 } { topic2 = notification.notified_object&.topic2 }
connected <span class="in-bold">{ topic2&.name }</span> to <span class="in-bold">{ topic1&.name }</span> connected <span className="in-bold">{ topic2&.name }</span> to <span className="in-bold">{ topic1&.name }</span>
{ when MESSAGE_FROM_DEVS } { when MESSAGE_FROM_DEVS }
{ notification.subject } { notification.subject }
{ end } { end }
</div> </div>
{ end } { end }
<div class="notification-read-unread"> <div className="notification-read-unread">
{ if receipt.is_read? } { if receipt.is_read? }
{ link_to 'mark as unread', mark_unread_notification_path(notification.id), remote: true, method: :put } { link_to 'mark as unread', mark_unread_notification_path(notification.id), remote: true, method: :put }
{ else } { else }
{ link_to 'mark as read', mark_read_notification_path(notification.id), remote: true, method: :put } { link_to 'mark as read', mark_read_notification_path(notification.id), remote: true, method: :put }
{ end } { end }
</div> </div>
<div class="notification-date"> <div className="notification-date">
{ notification.created_at.strftime("%b %d") } { notification.created_at.strftime("%b %d") }
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</li> </li>
{ end } { end }
{ if notifications.count == 0 } { if notifications.count == 0 }
<div class="emptyInbox"> <div className="emptyInbox">
You have no notifications. More time for dancing. You have no notifications. More time for dancing.
</div> </div>
{ end } { end }
@ -71,7 +71,7 @@
</div> </div>
{ if @notifications.total_pages > 1 } { if @notifications.total_pages > 1 }
<div class="centerContent withPadding pagination"> <div className="centerContent withPadding pagination">
{ paginate @notifications } { paginate @notifications }
</div> </div>
{ end } { end }

View file

@ -2,24 +2,24 @@
{ content_for :mobile_title, 'Notifications' } { content_for :mobile_title, 'Notifications' }
<div id="yield"> <div id="yield">
<div class="centerContent withPadding back"> <div className="centerContent withPadding back">
{ link_to 'Back to notifications', notifications_path } { link_to 'Back to notifications', notifications_path }
</div> </div>
<div class="centerContent notificationPage"> <div className="centerContent notificationPage">
<h2 class="notification-title"> <h2 className="notification-title">
{ case @notification.notification_code { case @notification.notification_code
when MAP_ACCESS_REQUEST when MAP_ACCESS_REQUEST
request = @notification.notified_object request = @notification.notified_object
map = request.map } map = request.map }
{ image_tag @notification.sender.image(:thirtytwo), class: 'thirty-two-avatar' } <span style='font-weight:bold;' class='requesterName'>{ request.user.name }</span> wants to collaborate on map <span style='font-weight:bold;'>{ map.name }</span> { image_tag @notification.sender.image(:thirtytwo), className: 'thirty-two-avatar' } <span style='font-weight:bold;' className='requesterName'>{ request.user.name }</span> wants to collaborate on map <span style='font-weight:bold;'>{ map.name }</span>
{ else } { else }
{ @notification.subject } { @notification.subject }
{ end } { end }
</h2> </h2>
{ case @notification.notification_code { case @notification.notification_code
when MAP_ACCESS_REQUEST } when MAP_ACCESS_REQUEST }
<div class="notification-body"> <div className="notification-body">
<p class="main-text"> <p className="main-text">
{ if false && request.answered } { if false && request.answered }
{ if request.approved } { if request.approved }
You already responded to this access request, and allowed access. You already responded to this access request, and allowed access.
@ -28,9 +28,9 @@
them access by going to the map and adding them as a collaborator. them access by going to the map and adding them as a collaborator.
{ end } { end }
{ else } { else }
{ image_tag asset_path('ellipsis.gif'), class: 'hidden' } { image_tag asset_path('ellipsis.gif'), className: 'hidden' }
{ link_to 'Allow', approve_access_post_map_path(id: map.id, request_id: request.id), remote: true, method: :post, class: 'button allow' } { link_to 'Allow', approve_access_post_map_path(id: map.id, request_id: request.id), remote: true, method: :post, className: 'button allow' }
{ link_to 'Decline', deny_access_post_map_path(id: map.id, request_id: request.id), remote: true, method: :post, class: 'button decline' } { link_to 'Decline', deny_access_post_map_path(id: map.id, request_id: request.id), remote: true, method: :post, className: 'button decline' }
<script> <script>
$(document).ready(function() { $(document).ready(function() {
$('.notification-body .button').click(function() { $('.notification-body .button').click(function() {
@ -44,7 +44,7 @@
&nbsp;&nbsp;{ link_to 'View mapper profile', explore_path(id: request.user.id) } &nbsp;&nbsp;{ link_to 'View mapper profile', explore_path(id: request.user.id) }
</div> </div>
{ else } { else }
<div class="notification-body"> <div className="notification-body">
{ raw @notification.body } { raw @notification.body }
</div> </div>
{ end } { end }

View file

@ -26,122 +26,122 @@
</ul> </ul>
<div id="csTopicView"> <div id="csTopicView">
<div class="csItem"><span class="csTitle">Enter Topic (radial) View:</span> Click on a Topic result from Search, or click the synapse <img src="{ asset_path 'synapse16.png' }" width="16" align="middle" /> icon inside open Topic Card on map</div> <div className="csItem"><span className="csTitle">Enter Topic (radial) View:</span> Click on a Topic result from Search, or click the synapse <img src="{ asset_path 'synapse16.png' }" width="16" align="middle" /> icon inside open Topic Card on map</div>
<div class="csItem"><span class="csTitle">Recenter Topics around chosen Topic:</span> Alt + click on the topic OR Alt + E</div> <div className="csItem"><span className="csTitle">Recenter Topics around chosen Topic:</span> Alt + click on the topic OR Alt + E</div>
<div class="csItem"><span class="csTitle">Reveal the siblings for a Topic:</span> Right-click and choose 'Reveal siblings' OR Alt + R</div> <div className="csItem"><span className="csTitle">Reveal the siblings for a Topic:</span> Right-click and choose 'Reveal siblings' OR Alt + R</div>
<div class="csItem"><span class="csTitle">Center topic and reveal siblings:</span> Alt + T</div> <div className="csItem"><span className="csTitle">Center topic and reveal siblings:</span> Alt + T</div>
<div class="csItem"><span class="csTitle">Filter out visible Topics:</span> Open Filter menu *** and toggle off/on</div> <div className="csItem"><span className="csTitle">Filter out visible Topics:</span> Open Filter menu *** and toggle off/on</div>
</div> </div>
<div id="csCreatingTopics"> <div id="csCreatingTopics">
<div class="csItem"><span class="csTitle">Double-click on canvas:</span> Bring up the metacode spinner</div> <div className="csItem"><span className="csTitle">Double-click on canvas:</span> Bring up the metacode spinner</div>
<div class="csItem indented"><span class="csTitle">Scroll:</span> change metacode spinner selection</div> <div className="csItem indented"><span className="csTitle">Scroll:</span> change metacode spinner selection</div>
<div class="csItem indented"><span class="csTitle">Tab:</span> rotate spinner counter-clockwise</div> <div className="csItem indented"><span className="csTitle">Tab:</span> rotate spinner counter-clockwise</div>
<div class="csItem indented"><span class="csTitle">Shift + tab:</span> rotate spinner clockwise</div> <div className="csItem indented"><span className="csTitle">Shift + tab:</span> rotate spinner clockwise</div>
<div class="csItem indented"><span class="csTitle">Esc:</span> Hides auto-suggestion results</div> <div className="csItem indented"><span className="csTitle">Esc:</span> Hides auto-suggestion results</div>
<div class="csItem indented"><span class="csTitle">Enter:</span> create a new topic</div> <div className="csItem indented"><span className="csTitle">Enter:</span> create a new topic</div>
<div class="csItem indented"><span class="csTitle">Gear Icon:</span> open up metacode settings</div> <div className="csItem indented"><span className="csTitle">Gear Icon:</span> open up metacode settings</div>
<div class="csItem"><br><a href="https://docs.metamaps.cc/creating_topics.html" target= "_blank">Learn More</a></div> <div className="csItem"><br><a href="https://docs.metamaps.cc/creating_topics.html" target= "_blank">Learn More</a></div>
</div> </div>
<div id="csEditingTopics"> <div id="csEditingTopics">
<div class="csItem"> <div className="csItem">
<span class="csTitle">Open Topic card:</span> Double-click on topic icon <span className="csTitle">Open Topic card:</span> Double-click on topic icon
</div> </div>
<div class="csItem indented"> <div className="csItem indented">
<span class="csTitle">Move Topic card:</span> Click and drag on topic card metacode <span className="csTitle">Move Topic card:</span> Click and drag on topic card metacode
</div> </div>
<div class="csItem indented"> <div className="csItem indented">
<span class="csTitle">Change metacode:</span> Mouse over metacode icon, then click on solid colored bar for metacode menu <span className="csTitle">Change metacode:</span> Mouse over metacode icon, then click on solid colored bar for metacode menu
</div> </div>
<div class="csItem indented"> <div className="csItem indented">
<span class="csTitle">Edit Topic title, description, link:</span> Click on text in respective area (click small "X" to reset link) <span className="csTitle">Edit Topic title, description, link:</span> Click on text in respective area (click small "X" to reset link)
</div> </div>
<div class="csItem indented"> <div className="csItem indented">
<span class="csTitle">Save Topic title, description, link:</span> Hit enter, or click away <span className="csTitle">Save Topic title, description, link:</span> Hit enter, or click away
</div> </div>
<div class="csItem indented"> <div className="csItem indented">
<span class="csTitle">Change Topic permission:</span> Click on 'Permission' icon (only for topic creator) <span className="csTitle">Change Topic permission:</span> Click on 'Permission' icon (only for topic creator)
</div> </div>
<div class="csItem indented"> <div className="csItem indented">
<span class="csTitle">Open Topic view:</span> Click on <img src="{ asset_path 'synapse16.png' }" width="16" align="middle" /> icon within topic card bar <span className="csTitle">Open Topic view:</span> Click on <img src="{ asset_path 'synapse16.png' }" width="16" align="middle" /> icon within topic card bar
</div> </div>
<div class="csItem indented"> <div className="csItem indented">
<span class="csTitle">Close Topic card:</span> Click on canvas <span className="csTitle">Close Topic card:</span> Click on canvas
</div> </div>
<div class="csItem"> <div className="csItem">
<span class="csTitle">Open 'Context Menu':</span> Right-click/alt+click on topic icon or synapse or selection (multiple) to Hide/Remove/Delete, change metacode or permission <span className="csTitle">Open 'Context Menu':</span> Right-click/alt+click on topic icon or synapse or selection (multiple) to Hide/Remove/Delete, change metacode or permission
</div> </div>
<div class="csItem"><br><a href="https://docs.metamaps.cc/creating_topics.html" target= "_blank">Learn More</a></div> <div className="csItem"><br><a href="https://docs.metamaps.cc/creating_topics.html" target= "_blank">Learn More</a></div>
</div> </div>
<div id="csCreatingSynapses"> <div id="csCreatingSynapses">
<div class="csItem"><span class="csTitle">Open 'Create Synapse' prompt:</span> Right-click & drag from one topic to another</div> <div className="csItem"><span className="csTitle">Open 'Create Synapse' prompt:</span> Right-click & drag from one topic to another</div>
<div class="csItem indented"><span class="csTitle">Enter a label</span> Begin typing (or leave blank)</div> <div className="csItem indented"><span className="csTitle">Enter a label</span> Begin typing (or leave blank)</div>
<div class="csItem indented"><span class="csTitle">Confirm new Synapse:</span> Enter or Tab</div> <div className="csItem indented"><span className="csTitle">Confirm new Synapse:</span> Enter or Tab</div>
<div class="csItem indented"><span class="csTitle">Cancel new Synapse:</span> Escape or Delete</div> <div className="csItem indented"><span className="csTitle">Cancel new Synapse:</span> Escape or Delete</div>
<div class="csItem"><span class="csTitle">Create new Topic with Synapse:</span> Right-click + drag from existing topic to open canvas</div> <div className="csItem"><span className="csTitle">Create new Topic with Synapse:</span> Right-click + drag from existing topic to open canvas</div>
<div class="csItem indented"><span class="csTitle">Create Topic:</span> Same as elsewhere</div> <div className="csItem indented"><span className="csTitle">Create Topic:</span> Same as elsewhere</div>
<div class="csItem indented"><span class="csTitle">Create Synapse:</span> Same as above</div> <div className="csItem indented"><span className="csTitle">Create Synapse:</span> Same as above</div>
<div class="csItem"><br><a href="https://docs.metamaps.cc/creating_synapses.html" target= "_blank">Learn More</a></div> <div className="csItem"><br><a href="https://docs.metamaps.cc/creating_synapses.html" target= "_blank">Learn More</a></div>
</div> </div>
<div id="csEditingSynapses"> <div id="csEditingSynapses">
<div class="csItem"><span class="csTitle">Open Synapse card:</span> Double-click on Synapse </div> <div className="csItem"><span className="csTitle">Open Synapse card:</span> Double-click on Synapse </div>
<div class="csItem indented"><span class="csTitle">Edit Synapse description:</span> Click on current description text</div> <div className="csItem indented"><span className="csTitle">Edit Synapse description:</span> Click on current description text</div>
<div class="csItem indented"><span class="csTitle">Save Synapse description:</span> Hit enter</div> <div className="csItem indented"><span className="csTitle">Save Synapse description:</span> Hit enter</div>
<div class="csItem indented"><span class="csTitle">Edit directionality:</span> Select appropriate arrow boxes</div> <div className="csItem indented"><span className="csTitle">Edit directionality:</span> Select appropriate arrow boxes</div>
<div class="csItem indented"><span class="csTitle">Change synapse permission:</span> Click on 'permission' icon (only for synapse creator)</div> <div className="csItem indented"><span className="csTitle">Change synapse permission:</span> Click on 'permission' icon (only for synapse creator)</div>
<div class="csItem indented"><span class="csTitle">Browse / select from multiple (stacked) synapses:</span> Click dropdown icon and select desired synapse</div> <div className="csItem indented"><span className="csTitle">Browse / select from multiple (stacked) synapses:</span> Click dropdown icon and select desired synapse</div>
<div class="csItem"><span class="csTitle">Open 'Context Menu':</span> Right-click/alt-click on Synapse</div> <div className="csItem"><span className="csTitle">Open 'Context Menu':</span> Right-click/alt-click on Synapse</div>
<div class="csItem indented">*Hide/Remove/Delete synapse within context menu</div> <div className="csItem indented">*Hide/Remove/Delete synapse within context menu</div>
<div class="csItem"><br><a href="https://docs.metamaps.cc/creating_synapses.html" target= "_blank">Learn More</a></div> <div className="csItem"><br><a href="https://docs.metamaps.cc/creating_synapses.html" target= "_blank">Learn More</a></div>
</div> </div>
<div id="csNavigation"> <div id="csNavigation">
<div class="csItem"><span class="csTitle">Move around Canvas:</span> Click and drag</div> <div className="csItem"><span className="csTitle">Move around Canvas:</span> Click and drag</div>
<div class="csItem indented"><span class="csTitle">Zoom in/out:</span> Scroll OR click on <div id="zoomIn"> </div> & <div id="zoomOut"> </div></div> <div className="csItem indented"><span className="csTitle">Zoom in/out:</span> Scroll OR click on <div id="zoomIn"> </div> & <div id="zoomOut"> </div></div>
<div class="csItem indented"><span class="csTitle">Zoom to see all:</span> Click <div id="centerMap"></div> OR Ctrl + E</div> <div className="csItem indented"><span className="csTitle">Zoom to see all:</span> Click <div id="centerMap"></div> OR Ctrl + E</div>
<div class="csItem"><span class="csTitle">Filter Map Contents:</span> Open the Filter Menu *** and toggle items off/on</div> <div className="csItem"><span className="csTitle">Filter Map Contents:</span> Open the Filter Menu *** and toggle items off/on</div>
<div class="csItem"><span class="csTitle">Return to 'Explore Maps' (home) page:</span> Click the Metamaps logo in the upper left corner</div> <div className="csItem"><span className="csTitle">Return to 'Explore Maps' (home) page:</span> Click the Metamaps logo in the upper left corner</div>
<div class="csItem"><br><a href="https://docs.metamaps.cc/exploring_maps.html" target= "_blank">Learn More</a></div> <div className="csItem"><br><a href="https://docs.metamaps.cc/exploring_maps.html" target= "_blank">Learn More</a></div>
</div> </div>
<div id="csSelection"> <div id="csSelection">
<div class="csItem"><span class="csTitle">Select/Deselect Topic:</span> Click on topic icon</div> <div className="csItem"><span className="csTitle">Select/Deselect Topic:</span> Click on topic icon</div>
<div class="csItem"><span class="csTitle">Select/Deselect Synapse:</span> Click on synapse</div> <div className="csItem"><span className="csTitle">Select/Deselect Synapse:</span> Click on synapse</div>
<div class="csItem"><span class="csTitle">Select multiple Topics/Synapses:</span> Shift + click to include each</div> <div className="csItem"><span className="csTitle">Select multiple Topics/Synapses:</span> Shift + click to include each</div>
<div class="csItem"><span class="csTitle">Select multiple with Selection Box:</span> Right-click/Shift-click + drag on Canvas</div> <div className="csItem"><span className="csTitle">Select multiple with Selection Box:</span> Right-click/Shift-click + drag on Canvas</div>
<div class="csItem"><span class="csTitle">Move all selected Topics & Synapses:</span> Click + drag on selected topic(s)/synapse(s)</div> <div className="csItem"><span className="csTitle">Move all selected Topics & Synapses:</span> Click + drag on selected topic(s)/synapse(s)</div>
<div class="csItem"><span class="csTitle">Open 'Context Menu':</span> Right-click/Alt-click on selected topic(s)</div> <div className="csItem"><span className="csTitle">Open 'Context Menu':</span> Right-click/Alt-click on selected topic(s)</div>
<div class="csItem indented">*Hide/Remove/Delete/Change permissions of multiple topics & synapses within context menu</div> <div className="csItem indented">*Hide/Remove/Delete/Change permissions of multiple topics & synapses within context menu</div>
<div class="csItem"><span class="csTitle">Zoom to selection box</span> Ctrl-click + drag</div> <div className="csItem"><span className="csTitle">Zoom to selection box</span> Ctrl-click + drag</div>
<div class="csItem"><span class="csTitle">Deselect all topics & Synapses:</span> Click on background or Esc</div> <div className="csItem"><span className="csTitle">Deselect all topics & Synapses:</span> Click on background or Esc</div>
</div> </div>
<div id="csSearch"> <div id="csSearch">
<div class="csItem"><span class="csTitle">Search for Topics and Maps:</span> Type query terms into search bar, wait for results below</div> <div className="csItem"><span className="csTitle">Search for Topics and Maps:</span> Type query terms into search bar, wait for results below</div>
<div class="csItem"><span class="csTitle">Limit search results:</span> Click checkbox for only items you created; click arrow above Topics or Maps section to collapse</div> <div className="csItem"><span className="csTitle">Limit search results:</span> Click checkbox for only items you created; click arrow above Topics or Maps section to collapse</div>
<div class="csItem"><span class="csTitle">Add Topic to current Map:</span> Click "+" on a topic result</div> <div className="csItem"><span className="csTitle">Add Topic to current Map:</span> Click "+" on a topic result</div>
<div class="csItem"><span class="csTitle">Jump to Topic View:</span> Click anywhere else on a topic result</div> <div className="csItem"><span className="csTitle">Jump to Topic View:</span> Click anywhere else on a topic result</div>
<div class="csItem"><span class="csTitle">Search by metacode:</span> type "[name of metacode]:", then your search query. i.e. idea:create...</div> <div className="csItem"><span className="csTitle">Search by metacode:</span> type "[name of metacode]:", then your search query. i.e. idea:create...</div>
<div class="csItem"><span class="csTitle">Search for map:</span> type "map:", then your search query. i.e. map:exploring...</div> <div className="csItem"><span className="csTitle">Search for map:</span> type "map:", then your search query. i.e. map:exploring...</div>
<div class="csItem"><span class="csTitle">Search for mapper:</span> type "mapper:", then your search query. i.e. mapper:Robert</div> <div className="csItem"><span className="csTitle">Search for mapper:</span> type "mapper:", then your search query. i.e. mapper:Robert</div>
</div> </div>
<div id="csKeyboardShortcuts"> <div id="csKeyboardShortcuts">
<div class="csItem"><span class="csTitle">Ctrl + /:</span> Open 'Search' prompt</div> <div className="csItem"><span className="csTitle">Ctrl + /:</span> Open 'Search' prompt</div>
<div class="csItem"><span class="csTitle">Ctrl + H:</span> Hide selection on map</div> <div className="csItem"><span className="csTitle">Ctrl + H:</span> Hide selection on map</div>
<div class="csItem"><span class="csTitle">Ctrl + M:</span> Remove selection from map</div> <div className="csItem"><span className="csTitle">Ctrl + M:</span> Remove selection from map</div>
<div class="csItem"><span class="csTitle">Ctrl + D:</span> Delete selection</div> <div className="csItem"><span className="csTitle">Ctrl + D:</span> Delete selection</div>
<div class="csItem"><span class="csTitle">Ctrl + A:</span> Select all topics</div> <div className="csItem"><span className="csTitle">Ctrl + A:</span> Select all topics</div>
<div class="csItem"><span class="csTitle">Ctrl + E:</span> See all on map (zoom to extents)</div> <div className="csItem"><span className="csTitle">Ctrl + E:</span> See all on map (zoom to extents)</div>
<div class="csItem"><span class="csTitle">Esc (while in search):</span> Close search</div> <div className="csItem"><span className="csTitle">Esc (while in search):</span> Close search</div>
<div class="csItem"><span class="csTitle">Esc (with selection):</span> Deselect all</div> <div className="csItem"><span className="csTitle">Esc (with selection):</span> Deselect all</div>
</div> </div>
</div> </div>
@ -151,8 +151,8 @@
<div id="moreResources"> <div id="moreResources">
<p>For more information about Metamaps.cc, visit our Knowledge Base or skip directly to a section by clicking on one of the categories below.</p> <p>For more information about Metamaps.cc, visit our Knowledge Base or skip directly to a section by clicking on one of the categories below.</p>
<div class="resourcesColumnOne resourcesColumn"> <div className="resourcesColumnOne resourcesColumn">
<a href="https://hylo.com/c/metamaps" target="_blank" class="button">Hylo User Community</a> <a href="https://hylo.com/c/metamaps" target="_blank" className="button">Hylo User Community</a>
<ul> <ul>
<li><a href="https://docs.metamaps.cc/getting_started.html" target="_blank">Getting Started</a></li> <li><a href="https://docs.metamaps.cc/getting_started.html" target="_blank">Getting Started</a></li>
<li><a href="https://docs.metamaps.cc/best_practices.html" target="_blank">Best Practices</a></li> <li><a href="https://docs.metamaps.cc/best_practices.html" target="_blank">Best Practices</a></li>
@ -160,8 +160,8 @@
<li><a href="https://docs.metamaps.cc/advanced_features.html" target="_blank">Advanced Features</a></li> <li><a href="https://docs.metamaps.cc/advanced_features.html" target="_blank">Advanced Features</a></li>
</ul> </ul>
</div> </div>
<div class="resourcesColumnTwo resourcesColumn"> <div className="resourcesColumnTwo resourcesColumn">
<a href="https://docs.metamaps.cc" target="_blank" class="button">KNOWLEDGE BASE</a> <a href="https://docs.metamaps.cc" target="_blank" className="button">KNOWLEDGE BASE</a>
<ul> <ul>
<li><a href="https://docs.metamaps.cc/general_questions.html" target="_blank">General Questions</a></li> <li><a href="https://docs.metamaps.cc/general_questions.html" target="_blank">General Questions</a></li>
<li><a href="https://docs.metamaps.cc/project_organization_and_governance.html" target="_blank">Organization & Governance</a></li> <li><a href="https://docs.metamaps.cc/project_organization_and_governance.html" target="_blank">Organization & Governance</a></li>

View file

@ -2,61 +2,61 @@
# @file # @file
# Partial view, renders a form that creates a new map. # Partial view, renders a form that creates a new map.
#} #}
<div class="onConsole"> <div className="onConsole">
{ form_for Map.new, url: maps_url, remote: true, html: { class: "new_map", id: "fork_map" } do |form|} { form_for Map.new, url: maps_url, remote: true, html: { className: "new_map", id: "fork_map" } do |form|}
<h3 class="forCreateMap">Save To New Map</h3> <h3 className="forCreateMap">Save To New Map</h3>
<div class="inputGroup"> <div className="inputGroup">
<label for="map_name">Name: </label> <label for="map_name">Name: </label>
{ form.text_field :name, :maxlength => 140 } { form.text_field :name, :maxlength => 140 }
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<div class="inputGroup"> <div className="inputGroup">
<label for="map_desc">Description: </label> <label for="map_desc">Description: </label>
{ form.text_area :desc, class: "description", :rows => 5, :cols => 43 } { form.text_area :desc, className: "description", :rows => 5, :cols => 43 }
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<div class="inputGroup"> <div className="inputGroup">
<label for="map_permission">Permission*: </label> <label for="map_permission">Permission*: </label>
<p class="permHelper">*new topics and synapses take on the same permission as the map they are created on</p> <p className="permHelper">*new topics and synapses take on the same permission as the map they are created on</p>
<div class="permIconWrapper"> <div className="permIconWrapper">
<div class="permIcon" data-permission="commons"> <div className="permIcon" data-permission="commons">
<div id="newmap_co" class="mapCommonsIcon mapPermIcon selected"> <div id="newmap_co" className="mapCommonsIcon mapPermIcon selected">
<div class="tip"> <div className="tip">
Anyone with an account can edit this map. Anyone without an account can only view it. Anyone with an account can edit this map. Anyone without an account can only view it.
</div> </div>
</div> </div>
<h4>COMMONS</h4> <h4>COMMONS</h4>
</div> </div>
<div class="permIcon" data-permission="public"> <div className="permIcon" data-permission="public">
<div id="newmap_pu" class="mapPublicIcon mapPermIcon"> <div id="newmap_pu" className="mapPublicIcon mapPermIcon">
<div class="tip"> <div className="tip">
Only people you allow can edit this map. Anyone can view it. Only people you allow can edit this map. Anyone can view it.
</div> </div>
</div> </div>
<h4>PUBLIC</h4> <h4>PUBLIC</h4>
</div> </div>
<div class="permIcon" data-permission="private"> <div className="permIcon" data-permission="private">
<div id="newmap_pr" class="mapPrivateIcon mapPermIcon"> <div id="newmap_pr" className="mapPrivateIcon mapPermIcon">
<div class="tip"> <div className="tip">
Only people you allow can edit this map. No one else can view it. Only people you allow can edit this map. No one else can view it.
</div> </div>
</div> </div>
<h4>PRIVATE</h4> <h4>PRIVATE</h4>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<p class="permText">Anyone with an account can edit this map. Anyone without an account can only view it.</p> <p className="permText">Anyone with an account can edit this map. Anyone without an account can only view it.</p>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<div class="buttonWrapper"> <div className="buttonWrapper">
<button class="button cancel">Cancel</button> <button className="button cancel">Cancel</button>
<button class="button submitMap">Create!</button> <button className="button submitMap">Create!</button>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
{ end } { end }
</div> </div>

View file

@ -1,3 +1,3 @@
<div class="unsubscribe-link"> <div className="unsubscribe-link">
{ link_to 'Unsubscribe from all Metamaps emails', unsubscribe_notifications_url(protocol: Rails.env.production? ? :https : :http) } { link_to 'Unsubscribe from all Metamaps emails', unsubscribe_notifications_url(protocol: Rails.env.production? ? :https : :http) }
</div> </div>

View file

@ -1,5 +1,5 @@
<style> <style>
{ # give text the color of the metacode by adding the class .metacodeColor{metacode-id} } { # give text the color of the metacode by adding the className .metacodeColor{metacode-id} }
{ Metacode.all.each do |m| } { Metacode.all.each do |m| }
{ if m.color } { if m.color }
{ ".metacodeColor" + m.id.to_s + "{" } { ".metacodeColor" + m.id.to_s + "{" }

View file

@ -34,18 +34,18 @@
data-metacodes="{ recent.map(&:id).join(',') }"> data-metacodes="{ recent.map(&:id).join(',') }">
{ @list = '' } { @list = '' }
{ recent.each_with_index do |m, index| } { recent.each_with_index do |m, index| }
{ @list += '<li><img src="' + asset_path(m.icon) + '" alt="' + m.name + '" /><p>' + m.name.downcase + '</p><div class="clearfloat"></div></li>' } { @list += '<li><img src="' + asset_path(m.icon) + '" alt="' + m.name + '" /><p>' + m.name.downcase + '</p><div className="clearfloat"></div></li>' }
{ end } { end }
<div class="metacodeSwitchTab"> <div className="metacodeSwitchTab">
<p class="setDesc">The 5 Metacodes you've used most recently.</p> <p className="setDesc">The 5 Metacodes you've used most recently.</p>
<div class="metacodeSetList"> <div className="metacodeSetList">
<ul> <ul>
{ @list.html_safe } { @list.html_safe }
</ul> </ul>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
</div> </div>
<button class="button" onclick="Metamaps.Create.updateMetacodeSet('Recent', 0, false);"> <button className="button" onclick="Metamaps.Create.updateMetacodeSet('Recent', 0, false);">
Switch Set Switch Set
</button> </button>
</div> </div>
@ -54,18 +54,18 @@
data-metacodes="{ most_used.map(&:id).join(',') }"> data-metacodes="{ most_used.map(&:id).join(',') }">
{ @list = '' } { @list = '' }
{ most_used.each_with_index do |m, index| } { most_used.each_with_index do |m, index| }
{ @list += '<li><img src="' + asset_path(m.icon) + '" alt="' + m.name + '" /><p>' + m.name.downcase + '</p><div class="clearfloat"></div></li>' } { @list += '<li><img src="' + asset_path(m.icon) + '" alt="' + m.name + '" /><p>' + m.name.downcase + '</p><div className="clearfloat"></div></li>' }
{ end } { end }
<div class="metacodeSwitchTab"> <div className="metacodeSwitchTab">
<p class="setDesc">The 5 Metacodes you've used the most.</p> <p className="setDesc">The 5 Metacodes you've used the most.</p>
<div class="metacodeSetList"> <div className="metacodeSetList">
<ul> <ul>
{ @list.html_safe } { @list.html_safe }
</ul> </ul>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
</div> </div>
<button class="button" onclick="Metamaps.Create.updateMetacodeSet('Most', 1, false);"> <button className="button" onclick="Metamaps.Create.updateMetacodeSet('Most', 1, false);">
Switch Set Switch Set
</button> </button>
</div> </div>
@ -74,46 +74,46 @@
data-metacodes="{ m.metacodes.map(&:id).join(',') }"> data-metacodes="{ m.metacodes.map(&:id).join(',') }">
{ @list = '' } { @list = '' }
{ m.metacodes.sort{|x,y| x.name <=> y.name }.each_with_index do |m, index| } { m.metacodes.sort{|x,y| x.name <=> y.name }.each_with_index do |m, index| }
{ @list += '<li><img src="' + asset_path(m.icon) + '" alt="' + m.name + '" /><p>' + m.name.downcase + '</p><div class="clearfloat"></div></li>' } { @list += '<li><img src="' + asset_path(m.icon) + '" alt="' + m.name + '" /><p>' + m.name.downcase + '</p><div className="clearfloat"></div></li>' }
{ end } { end }
<div class="metacodeSwitchTab"> <div className="metacodeSwitchTab">
<p class="setDesc">{ m.desc }</p> <p className="setDesc">{ m.desc }</p>
<div class="metacodeSetList"> <div className="metacodeSetList">
<ul> <ul>
{ @list.html_safe } { @list.html_safe }
</ul> </ul>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
</div> </div>
<button class="button" onclick="Metamaps.Create.updateMetacodeSet({ m.id }, { localindex + 2 }, false);"> <button className="button" onclick="Metamaps.Create.updateMetacodeSet({ m.id }, { localindex + 2 }, false);">
Switch Set Switch Set
</button> </button>
</div> </div>
{ end } { end }
<div id="metacodeSwitchTabsCustom"> <div id="metacodeSwitchTabsCustom">
<div class="setDesc">Choose Your Metacodes</div> <div className="setDesc">Choose Your Metacodes</div>
<div class="selectNone">NONE</div> <div className="selectNone">NONE</div>
<div class="selectAll">ALL</div> <div className="selectAll">ALL</div>
{ @list = '' } { @list = '' }
{ metacodesInUse = user_metacodes() } { metacodesInUse = user_metacodes() }
{ Metacode.order("name").all.each_with_index do |m, index| } { Metacode.order("name").all.each_with_index do |m, index| }
{ mClass = metacodesInUse.index(m) == nil ? "toggledOff" : "" } { mClass = metacodesInUse.index(m) == nil ? "toggledOff" : "" }
{ @list += '<li id="' + m.id.to_s + '" data-name="' + m.name + '" class="' + mClass + '"><img src="' + asset_path(m.icon) + '" alt="' + m.name + '" /><p>' + m.name.downcase + '</p><div class="clearfloat"></div></li>' } { @list += '<li id="' + m.id.to_s + '" data-name="' + m.name + '" className="' + mClass + '"><img src="' + asset_path(m.icon) + '" alt="' + m.name + '" /><p>' + m.name.downcase + '</p><div className="clearfloat"></div></li>' }
{ end } { end }
<div class="customMetacodeList"> <div className="customMetacodeList">
<ul> <ul>
{ @list.html_safe } { @list.html_safe }
</ul> </ul>
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
<button class="button" onclick="Metamaps.Create.updateMetacodeSet('custom', { allMetacodeSets.length + 2 }, true);"> <button className="button" onclick="Metamaps.Create.updateMetacodeSet('custom', { allMetacodeSets.length + 2 }, true);">
Switch to Custom Set Switch to Custom Set
</button> </button>
</div> </div>
</div> </div>
<div class="clearfloat"></div> <div className="clearfloat"></div>
<script> <script>
Metamaps.Create.selectedMetacodeSet = "metacodeset-{ selectedSet }" Metamaps.Create.selectedMetacodeSet = "metacodeset-{ selectedSet }"

View file

@ -7,81 +7,81 @@
{ content_for :title, @user.name + "'s Settings | Metamaps" } { content_for :title, @user.name + "'s Settings | Metamaps" }
{ content_for :mobile_title, "Account Settings" } { content_for :mobile_title, "Account Settings" }
<div id="yield"> <div id="yield">
{ form_for @user, url: user_url, :html =>{ :multipart => true, :class => "edit_user centerGreyForm"} do |form| } { form_for @user, url: user_url, :html =>{ :multipart => true, :className => "edit_user centerGreyForm"} do |form| }
<h3>Edit Settings</h3> <h3>Edit Settings</h3>
<div class="userImage"> <div className="userImage">
<div class="userImageDiv" onclick="Metamaps.Account.toggleChangePicture()"> <div className="userImageDiv" onclick="Metamaps.Account.toggleChangePicture()">
{ image_tag @user.image.url(:ninetysix), :size => "84x84" } { image_tag @user.image.url(:ninetysix), :size => "84x84" }
<div class="editPhoto"></div> <div className="editPhoto"></div>
</div> </div>
<div class="userImageMenu"> <div className="userImageMenu">
<div class="userMenuArrow"></div> <div className="userMenuArrow"></div>
<ul> <ul>
<li class="upload"> <li className="upload">
Upload Photo Upload Photo
{ hidden_field_tag "remove_image", "0" } { hidden_field_tag "remove_image", "0" }
{ form.file_field :image } { form.file_field :image }
{ form.label :image } { form.label :image }
</li> </li>
<li class="remove" onclick="Metamaps.Account.removePicture()">Remove</li> <li className="remove" onclick="Metamaps.Account.removePicture()">Remove</li>
<li class="cancel" onclick="Metamaps.Account.closeChangePicture()">Cancel</li> <li className="cancel" onclick="Metamaps.Account.closeChangePicture()">Cancel</li>
</ul> </ul>
</div> </div>
</div> </div>
<div class="accountName" onclick="Metamaps.Account.changeName()"> <div className="accountName" onclick="Metamaps.Account.changeName()">
<div class="nameEdit">{ @user.name }</div> <div className="nameEdit">{ @user.name }</div>
</div> </div>
<div class="changeName"> <div className="changeName">
{ form.label :name, "Name:", class: 'firstFieldText' } { form.label :name, "Name:", className: 'firstFieldText' }
{ form.text_field :name } { form.text_field :name }
</div> </div>
<div> <div>
{ form.label :email, "Email:", class: 'firstFieldText' } { form.label :email, "Email:", className: 'firstFieldText' }
{ form.email_field :email } { form.email_field :email }
</div> </div>
<div> <div>
{ form.label :emails_allowed, class: 'firstFieldText' do } { form.label :emails_allowed, className: 'firstFieldText' do }
{ form.check_box :emails_allowed, class: 'inline' } { form.check_box :emails_allowed, className: 'inline' }
Send Metamaps notifications to my email. Send Metamaps notifications to my email.
{ end } { end }
{ fields_for :settings, @user.settings do |settings| } { fields_for :settings, @user.settings do |settings| }
{ settings.label :follow_topic_on_created, class: 'firstFieldText' do } { settings.label :follow_topic_on_created, className: 'firstFieldText' do }
{ settings.check_box :follow_topic_on_created, class: 'inline' } { settings.check_box :follow_topic_on_created, className: 'inline' }
Auto-follow topics you create. Auto-follow topics you create.
{ end } { end }
{ settings.label :follow_topic_on_contributed, class: 'firstFieldText' do } { settings.label :follow_topic_on_contributed, className: 'firstFieldText' do }
{ settings.check_box :follow_topic_on_contributed, class: 'inline' } { settings.check_box :follow_topic_on_contributed, className: 'inline' }
Auto-follow topics you edit. Auto-follow topics you edit.
{ end } { end }
{ settings.label :follow_map_on_created, class: 'firstFieldText' do } { settings.label :follow_map_on_created, className: 'firstFieldText' do }
{ settings.check_box :follow_map_on_created, class: 'inline' } { settings.check_box :follow_map_on_created, className: 'inline' }
Auto-follow maps you create. Auto-follow maps you create.
{ end } { end }
{ settings.label :follow_map_on_contributed, class: 'firstFieldText' do } { settings.label :follow_map_on_contributed, className: 'firstFieldText' do }
{ settings.check_box :follow_map_on_contributed, class: 'inline' } { settings.check_box :follow_map_on_contributed, className: 'inline' }
Auto-follow maps you edit. Auto-follow maps you edit.
{ end } { end }
{ end } { end }
</div> </div>
<div class="changePass" onclick="Metamaps.Account.showPass()">Change Password</div> <div className="changePass" onclick="Metamaps.Account.showPass()">Change Password</div>
<div class="toHide"> <div className="toHide">
<div> <div>
{ form.label :current_password, "Current Password:", :class => "firstFieldText" } { form.label :current_password, "Current Password:", :className => "firstFieldText" }
{ password_field_tag :current_password, params[:current_password] } { password_field_tag :current_password, params[:current_password] }
</div> </div>
<div> <div>
{ form.label :password, "New Password:", :class => "firstFieldText" } { form.label :password, "New Password:", :className => "firstFieldText" }
{ form.password_field :password, :autocomplete => :off} { form.password_field :password, :autocomplete => :off}
</div> </div>
<div> <div>
{ form.label :password_confirmation, "Confirm New Password:", :class => "firstFieldText" } { form.label :password_confirmation, "Confirm New Password:", :className => "firstFieldText" }
{ form.password_field :password_confirmation, :autocomplete => :off} { form.password_field :password_confirmation, :autocomplete => :off}
</div> </div>
<div class="noChangePass" onclick="Metamaps.Account.hidePass()">Oops, don't change password</div> <div className="noChangePass" onclick="Metamaps.Account.hidePass()">Oops, don't change password</div>
</div> </div>
<div id="accountPageLoading"></div> <div id="accountPageLoading"></div>
{ form.submit "Update", class: "update", onclick: "Metamaps.Account.showLoading()" } { form.submit "Update", className: "update", onclick: "Metamaps.Account.showLoading()" }
<div class="clearfloat"></div> <div className="clearfloat"></div>
{ end } { end }
</div> </div>

View file

@ -2,15 +2,15 @@
{ content_for :mobile_title, "Change Password" } { content_for :mobile_title, "Change Password" }
<div id="yield"> <div id="yield">
{ form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put, :class => "forgotPassword centerGreyForm forgotPasswordReset" }) do |f| } { form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put, :className => "forgotPassword centerGreyForm forgotPasswordReset" }) do |f| }
{ f.hidden_field :reset_password_token } { f.hidden_field :reset_password_token }
<h3>Change password</h3> <h3>Change password</h3>
<div>{ f.label :password, "New password", :class => "firstFieldText" } <div>{ f.label :password, "New password", :className => "firstFieldText" }
{ f.password_field :password, :autofocus => true }</div> { f.password_field :password, :autofocus => true }</div>
<div>{ f.label :password_confirmation, "Confirm new password", :class => "firstFieldText" } <div>{ f.label :password_confirmation, "Confirm new password", :className => "firstFieldText" }
{ f.password_field :password_confirmation }</div> { f.password_field :password_confirmation }</div>
<div>{ f.submit "Change my password" }</div> <div>{ f.submit "Change my password" }</div>

View file

@ -2,11 +2,11 @@
{ content_for :mobile_title, "Password Reset" } { content_for :mobile_title, "Password Reset" }
<div id="yield"> <div id="yield">
{ form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :post, :class => "forgotPassword centerGreyForm" }) do |f| } { form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :post, :className => "forgotPassword centerGreyForm" }) do |f| }
<h3>FORGOT PASSWORD?</h3> <h3>FORGOT PASSWORD?</h3>
<div>{ f.label :email, "Enter your email:", :class => "firstFieldText" } <div>{ f.label :email, "Enter your email:", :className => "firstFieldText" }
{ f.email_field :email, :autofocus => true }</div> { f.email_field :email, :autofocus => true }</div>
<div>{ f.submit "Send Password Reset Instructions" }</div> <div>{ f.submit "Send Password Reset Instructions" }</div>

View file

@ -2,28 +2,28 @@
{ content_for :mobile_title, "Join" } { content_for :mobile_title, "Join" }
<div id="yield"> <div id="yield">
{ form_for(resource, :as => resource_name, :url => registration_path(resource_name), :html => { :method => :post, :class => "new_user centerGreyForm" }) do |f| } { form_for(resource, :as => resource_name, :url => registration_path(resource_name), :html => { :method => :post, :className => "new_user centerGreyForm" }) do |f| }
<h3>Sign Up</h3> <h3>Sign Up</h3>
<div>{ f.label :name, "Name:", :class => "firstFieldText" } <div>{ f.label :name, "Name:", :className => "firstFieldText" }
{ f.text_field :name, :autofocus => true }</div> { f.text_field :name, :autofocus => true }</div>
<div>{ f.label :email, "Email:", :class => "fieldText" } <div>{ f.label :email, "Email:", :className => "fieldText" }
{ f.email_field :email }</div> { f.email_field :email }</div>
<div>{ f.label :password, "Password:", :class => "fieldText" } <div>{ f.label :password, "Password:", :className => "fieldText" }
{ f.password_field :password }</div> { f.password_field :password }</div>
<div>{ f.label :password_confirmation, "Password Confirmation:", :class => "fieldText" } <div>{ f.label :password_confirmation, "Password Confirmation:", :className => "fieldText" }
{ f.password_field :password_confirmation }</div> { f.password_field :password_confirmation }</div>
<div>{ f.label "Access Code:", :class => "fieldText" } <div>{ f.label "Access Code:", :className => "fieldText" }
{ f.text_field :joinedwithcode, :value => params[:code] }</div> { f.text_field :joinedwithcode, :value => params[:code] }</div>
<div>{ f.submit "Sign up!" }</div> <div>{ f.submit "Sign up!" }</div>
<div class = "smallText"><br />Don't have an access code?<br /><a href="/request">Request an Invite</a></div> <div className = "smallText"><br />Don't have an access code?<br /><a href="/request">Request an Invite</a></div>
{ end } { end }
</div> </div>

View file

@ -2,27 +2,27 @@
{ content_for :mobile_title, "Login" } { content_for :mobile_title, "Login" }
<div id="yield"> <div id="yield">
{ form_for(resource, :as => resource_name, :url => session_path(resource_name), :html => { :method => :post, :class => "centerGreyForm login" }) do |f| } { form_for(resource, :as => resource_name, :url => session_path(resource_name), :html => { :method => :post, :className => "centerGreyForm login" }) do |f| }
<h3>SIGN IN</h3> <h3>SIGN IN</h3>
<div class="accountImage"></div> <div className="accountImage"></div>
<div> <div>
{ f.email_field :email, :autofocus => true, :placeholder => "Email" }</div> { f.email_field :email, :autofocus => true, :placeholder => "Email" }</div>
<div> <div>
{ f.password_field :password, :placeholder => "Password" }</div> { f.password_field :password, :placeholder => "Password" }</div>
<div class="accountSubmit">{ f.submit "Sign in" }</div> <div className="accountSubmit">{ f.submit "Sign in" }</div>
{ if devise_mapping.rememberable? -} { if devise_mapping.rememberable? -}
<div class="accountRememberMe"> <div className="accountRememberMe">
{ f.label :remember_me, "Stay signed in" } { f.label :remember_me, "Stay signed in" }
{ f.check_box :remember_me } { f.check_box :remember_me }
<div class="clearfloat"></div> <div className="clearfloat"></div>
</div> </div>
{ end -} { end -}
<div class="clearfloat"></div> <div className="clearfloat"></div>
<div class="accountForgotPass"> <div className="accountForgotPass">
{- if devise_mapping.recoverable? && controller_name != 'passwords' } {- if devise_mapping.recoverable? && controller_name != 'passwords' }
{ link_to "Forgot password?", new_password_path(resource_name) } { link_to "Forgot password?", new_password_path(resource_name) }
{ end -} { end -}

View file

@ -14,12 +14,12 @@
{ link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name) }<br /> { link_to "Didn't receive confirmation instructions?", new_confirmation_path(resource_name) }<br />
{ end -} { end -}
{- if devise_mapping.lockable? && resource_class.unlock_strategy_enabled?(:email) && controller_name != 'unlocks' } {- if devise_mapping.lockable? && resource_className.unlock_strategy_enabled?(:email) && controller_name != 'unlocks' }
{ link_to "Didn't receive unlock instructions?", new_unlock_path(resource_name) }<br /> { link_to "Didn't receive unlock instructions?", new_unlock_path(resource_name) }<br />
{ end -} { end -}
{- if devise_mapping.omniauthable? } {- if devise_mapping.omniauthable? }
{- resource_class.omniauth_providers.each do |provider| } {- resource_className.omniauth_providers.each do |provider| }
{ link_to "Sign in with #{provider.to_s.titleize}", omniauth_authorize_path(resource_name, provider) }<br /> { link_to "Sign in with #{provider.to_s.titleize}", omniauth_authorize_path(resource_name, provider) }<br />
{ end -} { end -}
{ end -} { end -}