New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
micropost create controller, views, infinite-scroll, add stimulus.js #62
Conversation
|
||
body { | ||
background-color: $background-color; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
тут що
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
фон для контента, в colors.scss
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
що з форматуванням
= micropost.title | ||
hr/ | ||
= image_tag micropost.image.url, class: "img-fluid" if micropost.image? | ||
/img.img-fluid src="https://i.imgur.com/xhzhaGA.jpg" / |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
нащо цей комент тут
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
видалю, тестив просто
= link_to 'New', new_account_micropost_path, class: 'btn btn-outline-success' | ||
div data-controller="infinite-scroll" data-action="scroll@window->infinite-scroll#scroll" | ||
div data-infinite-scroll-target="entries" | ||
= render 'account/microposts/microposts' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
паршали немають мати інстанс змінних, туди передаватись має
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
поміняю
format.html | ||
format.json { | ||
render json: { entries: render_to_string(partial: "microposts.html.slim", formats: [:html]), | ||
pagination: render_to_string(partial: "paginate.html.slim") } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
а тут не треба вказувати формат як вище?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
вкажу
Admin create microposts, micropost views, infinitescroll
Changes description
add microposts controller
add micropost views
admin can create, delete micropost (with ajax)
infinite-scroll for microposts feed
update seeds
update factory
Screnshots of the added pages
admin view:
view mobile:
user view:
Check list: