add basic react wrapper code

This commit is contained in:
Connor Turland 2018-03-05 13:18:51 -05:00
parent a72b4c6871
commit a9f353a07f
19 changed files with 190 additions and 0 deletions

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent">
<div className="page-header">
@ -7,4 +12,9 @@
{ render 'form', application: @application }
</div>
</div>
)
}
}
export default MyComponent
{ render 'script' }

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent">
<div className="page-header">
@ -25,4 +30,9 @@
{ link_to t('.new'), new_oauth_application_path, className: 'button link-button' }
</div>
</div>
)
}
}
export default MyComponent
{ render 'script' }

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent">
{ link_to t('doorkeeper.applications.buttons.back'), oauth_applications_path(), className: 'button link-button button-margin' }
@ -8,4 +13,9 @@
{ render 'form', application: @application }
</div>
</div>
)
}
}
export default MyComponent
{ render 'script' }

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent showApp">
@ -34,4 +39,9 @@
<div className="inline-button">{ render 'delete_form', application: @application, submit_btn_css: 'button red-button' }</div>
</div>
</div>
)
}
}
export default MyComponent
{ render 'script' }

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent">
<div className="page-header">
@ -9,3 +14,8 @@
</main>
</div>
</div>
)
}
}
export default MyComponent

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent">
<header className="page-header" role="banner">
@ -46,3 +51,8 @@
</main>
</div>
</div>
)
}
}
export default MyComponent

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent">
<header className="page-header">
@ -9,3 +14,8 @@
</main>
</div>
</div>
)
}
}
export default MyComponent

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent">
<header className="page-header">
@ -34,4 +39,9 @@
</main>
</div>
</div>
)
}
}
export default MyComponent
{ render 'script' }

View file

@ -1,8 +1,18 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className='centerContent'>
{ render 'form' }
</div>
</div>
)
}
}
export default MyComponent
<script>
{ Metacode.all.each do |m| }

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className='centerContent'>
<br />
@ -34,3 +39,8 @@
</table>
</div>
</div>
)
}
}
export default MyComponent

View file

@ -1,8 +1,18 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className='centerContent'>
{ render 'form' }
</div>
</div>
)
}
}
export default MyComponent
<script>
{ Metacode.all.each do |m| }

View file

@ -1,5 +1,15 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className='centerContent'>
{ render 'form' }
</div>
</div>
)
}
}
export default MyComponent

View file

@ -1,3 +1,8 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className='centerContent'>
<br />
@ -28,3 +33,8 @@
</table>
</div>
</div>
)
}
}
export default MyComponent

View file

@ -1,5 +1,15 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className='centerContent'>
{ render 'form' }
</div>
</div>
)
}
}
export default MyComponent

View file

@ -1,6 +1,11 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent notificationsPage">
<header className="page-header">
@ -76,3 +81,8 @@
</div>
{ end }
</div>
)
}
}
export default MyComponent

View file

@ -1,6 +1,11 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
<div className="centerContent withPadding back">
{ link_to 'Back to notifications', notifications_path }
@ -50,3 +55,8 @@
{ end }
</div>
</div>
)
}
}
export default MyComponent

View file

@ -2,6 +2,11 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
{ form_for @user, url: user_url, :html =>{ :multipart => true, :className => "edit_user centerGreyForm"} do |form| }
<h3>Edit Settings</h3>
@ -81,3 +86,8 @@
<div className="clearfloat"></div>
{ end }
</div>
)
}
}
export default MyComponent

View file

@ -1,6 +1,11 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
{ 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 }
@ -17,4 +22,9 @@
{ end }
</div>
)
}
}
export default MyComponent

View file

@ -1,6 +1,11 @@
import React, { Component } from react
class MyComponent extends Component {
render = () => {
return (
<div id="yield">
{ form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :post, :className => "forgotPassword centerGreyForm" }) do |f| }
@ -13,5 +18,10 @@
{ end }
</div>
)
}
}
export default MyComponent