ModalProfile.razor 3.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. <div class="modal" tabindex="-1" role="dialog" style="display:none" id="@elementid">
  2. <div class="modal-container">
  3. <div class="modal__body">
  4. <div class="modal__body__header">
  5. <div class="modal__body__header__info">
  6. <img src="img/packet.svg" alt="">
  7. <p>Персональные данные</p>
  8. </div>
  9. </div>
  10. <div class="modal__body__container">
  11. <div class="modal__body__container__left modal__body__container__left_blackborder modal__body__container__left_flex">
  12. <div class="modal__profile__photo">
  13. <img src="img/profile_avatar.png" alt="" class="modal__profile__img">
  14. <img src="img/camera.png" alt="" class="modal__profile__img__icon">
  15. </div>
  16. <div class="modal__profile__social">
  17. <a href="" class="modal__profile__social__item">
  18. <img src="img/facebook_icon.svg" alt="">
  19. </a>
  20. <a href="" class="modal__profile__social__item">
  21. <img src="img/instagram_icon.svg" alt="">
  22. </a>
  23. <a href="" class="modal__profile__social__item">
  24. <img src="img/twitter_icon.svg" alt="">
  25. </a>
  26. <a href="" class="modal__profile__social__item">
  27. <img src="img/pinterest_icon.svg" alt="">
  28. </a>
  29. <a href="" class="modal__profile__social__item">
  30. <img src="img/tiktok.svg" alt="">
  31. </a>
  32. <a href="" class="modal__profile__social__item">
  33. <img src="img/whatsapp.svg" alt="">
  34. </a>
  35. <a href="" class="modal__profile__social__item">
  36. <img src="img/youtube_icon.svg" alt="">
  37. </a>
  38. </div>
  39. </div>
  40. <div class="modal__body__container__right modal__body__container__right_blackborder">
  41. <p class="modal__profile__text">@_account.Name</p>
  42. <p class="modal__profile__text"> </p>
  43. <p class="modal__profile__text modal__profile__text_mb" style="font-size:small">@_account.UUID</p>
  44. <p class="modal__profile__text modal__profile__text_mb">@whereFrom</p>
  45. <p class="modal__profile__text">@veryfied</p>
  46. <p class="modal__profile__text">Статус: @status</p>
  47. <p class="modal__profile__text">Роль: @(string.Join(", ", _account.GetRoleDisplayName()))</p>
  48. </div>
  49. </div>
  50. </div>
  51. <a class="modal_close" style="cursor:pointer" @onclick="@Close">&#10006;</a>
  52. </div>
  53. </div>
  54. @code {
  55. [Inject]
  56. public IJSRuntime JsRuntime { get; set; }
  57. [Parameter]
  58. public RenderFragment Title { get; set; }
  59. private string elementid = "modal_profile";
  60. Models.AccountModel _account = new();
  61. /// tmp
  62. string whereFrom = "г. Санкт-Петербург";
  63. string veryfied = "Верифицирован";
  64. string status = "свободен";
  65. public void Open(Models.AccountModel account)
  66. {
  67. JsRuntime.InvokeVoidAsync("OpenModal", elementid);
  68. if (account != null)
  69. {
  70. _account = account;
  71. }
  72. }
  73. public void Close()
  74. {
  75. JsRuntime.InvokeVoidAsync("CloseModal", elementid);
  76. }
  77. }