ソーシャルゲームのフロントエンドとASP.NET MVC (Lite)

ソーシャルゲームのフロントエンドとASP.NET MVC (Lite)

Room metro Tokyo #3 (2014-01-18)

1fe26e11357f3ba7250b6668ca61309f?s=128

Mayuki Sawatari

January 18, 2014
Tweet

Transcript

  1. 1.
  2. 3.
  3. 4.

    ( )

  4. 5.
  5. 6.
  6. 8.
  7. 10.
  8. 11.
  9. 12.
  10. 13.
  11. 14.
  12. 16.
  13. 19.

    <div class="block"> <div class="block__element">Hauhau</div> <div class="block__element--modifier">Gaogao</div> </div> <div class="listview"> <div

    class="listview__item">Item1</div> <div class="listview__item--selected">Item2(Selected)</div> </div>
  14. 20.

    <div class="block"> <div class="block_element">Hauhau</div> <div class="block_element-Modifier">Gaogao</div> </div> <div class="listview"> <div

    class="listview_item">Item1</div> <div class="listview_item-Selected">Item2(Selected)</div> </div>
  15. 21.
  16. 23.
  17. 24.
  18. 26.
  19. 28.

    var content = @ <ul> <li><a href=""#"">1</a></li> <li><a href=""#"">2</a></li> </ul>";

    var htmlFilter = new HtmlFilter(); htmlFilter.AddHandler("li:nth-child(2n)", (ctx, nodeInfo) => { nodeInfo.Attributes["style"] = "color:red;"; return true; }); var sw = new StringWriter(); htmlFilter.Execute(new CarteletContext(content, sw), HtmlParser.Parse(content)); sw.ToString(); // <ul> // <li><a href="#">1</a></li> // <li style="color:red;"><a href="#">2</a></li> // </ul>
  20. 30.
  21. 34.
  22. 36.
  23. 37.