in-silico / judge-frontend

Frontend to UTPJudge
Mozilla Public License 2.0
3 stars 2 forks source link

Features #32

Closed sebas095 closed 8 years ago

sebas095 commented 8 years ago

@pin3da

leiverandres commented 8 years ago

I doesn't work fully yet ...

sebas095 commented 8 years ago

Today I check it and correct it!

pin3da commented 8 years ago

Hi,

first of all thanks for your work, is really appreciated.

I tried to start the project and it does not work, the browser/main file has problems with the opening/closing brackets, it also includes files that are not in the repo.

After that i tried to understand the code and I found several inconsistencies.

Try to refactor the PR and let me know when it works, I'll review again and I'll give you more feedback.

sebas095 commented 8 years ago

the json folder was only for to do testing, but I later fix it (when I get home)

leiverandres commented 8 years ago
sebas095 commented 8 years ago

@leiverandres Tomorrow do we fix everything?

caal-15 commented 8 years ago

The main point of using pure css is to style the classes you create in React, so you can style them directly from the css:

var myClass = React.createClass({
  render: function (){
    return (
      <div className="myClass">
        ...
      </div>
    );
  }
});

Note that the only property given is a custom className, and then on the CSS

.myClass {
  padding: 15px;
  ...
}

And for a specific component inside the class

.myClass table {
  color: blue;
  ...
}

Note also that we are using React.createClass(), this is due to a discussion with @pin3da regarding the support for ES6 and the other syntax, please use the React.createClass() syntax in the future.

caal-15 commented 8 years ago

@leiverandres The developed component for listing problems was created with the purpose of adding problems to a contest in mind, however it also serves as a component to list all the problems, I would suggest you look at the component I created and modify it if you think something is missing, rather than using your own.

leiverandres commented 8 years ago

Perfect. I'll keep that un mind

caal-15 commented 8 years ago

Oh, i forgot something, if you want to use the grid, use it on the html component you are going to render your component into, for example you want your component to be in a row and be 4 columns wide:

On the view.ejs

<% include header %>
  <div class="row">
    <div class="col-4" id="container">
    </div>
  </div>

On the main.js

ReactDOM.render(
  <myClass />,
  document.getElementById('container')
);
leiverandres commented 8 years ago

@pin3da @caal-15 guys We think its ok to merge ... We did:

Coming:

If something missed please tell us :smile:

sebas095 commented 8 years ago

@aerendon What ideas do you have for improving the style?

pin3da commented 8 years ago

I reviewed the patch, some observations:

I would merge if you want, but in my opinion we need to stabilize all that work before.

sebas095 commented 8 years ago

I'll organize some things carlos told me

sebas095 commented 8 years ago

@pin3da and @caal-15 check it P.D. sorry for the triple commit was not my intention D:

pin3da commented 8 years ago

It seems to work now, two things before merge.

Great work ! :+1:

pin3da commented 8 years ago

@sebas095 @leiverandres @aerendon @caal-15 Merged... Thanks :tada: :confetti_ball: