Skip to content

[WIP] Enhance cover section by enabling user to change bg color #6

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

Closed
wants to merge 1 commit into from

Conversation

nanophate
Copy link
Member

@nanophate nanophate commented May 18, 2016

やりたいこと

ユーザーが自在にバックグラウンドの背景の色を変更できる様にする。
#3 で問い合わせた内容の対応

PR #3 で問い合わせた内容の返事

Hey YassLab,
I think I described it a bit short. Lets assume you have in your model the following attribute:
attribute: background_color_select, :enum, values: ["red","green","blue"], default: "red"
Then in your details view you would offer this attribute for editing as follows:
scrivito_tag(:div, widget, :background_color_select)
Finally in your widgets view you would have something along the following lines:

...

This way the background colour of your widget is changeable by your used.
Bartek from Scrivito
PS: Did you know that there's a one-hour Google Hangout with our developers called "Ask Scrivito" every Monday, starting at 4:00 pm CET (Berlin Time) / 10:00 am EST?
https://plus.google.com/hangouts/_/infopark.de/ask-scrivito

やること

  • Codeが実際に動くか確認する。
  • ユーザー側の入力の誤認を対応できる様にする。

@nanophate nanophate changed the title Enhance Cover Section #3 [WIP]Enhance cover section by enabling user to change bg color May 18, 2016
@nanophate
Copy link
Member Author

Scrivitoの既存のgemにColor Picker機能を発見。
#9 にも似たような応用ができそうな感じがする。

@yasulab
Copy link
Member

yasulab commented May 30, 2016

Scrivitoの既存のgemにColor Picker機能を発見。
#9 にも似たような応用ができそうな感じがする。

お、いい発見だね! 余裕があれば、gemの内部のソースコードを読んで勉強してみるのも良いかも 🔍

@nanophate
Copy link
Member Author

余裕があれば、gemの内部のソースコードを読んで勉強してみるのも良いかも 🔍

ありがとうございます。
他人のコードを見て理解する力は必要ですね。挑戦してみます。

@yasulab yasulab changed the title [WIP]Enhance cover section by enabling user to change bg color [WIP] Enhance cover section by enabling user to change bg color Dec 17, 2016
@yasulab
Copy link
Member

yasulab commented Jan 15, 2017

こっちも解決しているので閉じちゃいます! ✅

@yasulab yasulab closed this Jan 15, 2017
@yasulab yasulab deleted the new-paragraph-ft-with-color-choice branch January 15, 2017 04:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants