-
Notifications
You must be signed in to change notification settings - Fork 67
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3fe3172
commit ee61597
Showing
7 changed files
with
176 additions
and
138 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
117 changes: 1 addition & 116 deletions
117
src/ghosts.pandora.socializer/src/Views/Home/Index.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,8 +6,8 @@ | |
{ | ||
var u = new Socializer.Infrastructure.User(); | ||
var number = rnd.Next(1, 85); | ||
u.Avatar = $"/img/avatar{number}-sm.webp"; | ||
u.Name = Faker.Internet.UserName(); | ||
u.Avatar = $"/u/{u.Name}/avatar"; | ||
if(rnd.Next(1, 3) > 1) | ||
u.Name = Faker.Name.FullName(); | ||
u.Status = statusArray[rnd.Next(statusArray.Length)]; | ||
|
@@ -805,14 +805,14 @@ | |
<script src="/js/main.js"></script> | ||
<script src="/js/libs-init/libs-init.js"></script> | ||
|
||
<script src="Bootstrap/dist/js/bootstrap.bundle.min.js"></script> | ||
<script src="/Bootstrap/dist/js/bootstrap.bundle.min.js"></script> | ||
|
||
<!-- SVG icons loader --> | ||
<script src="/js/svg-loader.js"></script> | ||
<!-- /SVG icons loader --> | ||
|
||
<script src="~/js/signalr.min.js"></script> | ||
<script src="~/js/posts.js" asp-append-version="true"></script> | ||
<script src="~/js/posts.js[email protected]()" asp-append-version="true"></script> | ||
|
||
@await RenderSectionAsync("Scripts", required: false) | ||
</body> | ||
|
116 changes: 116 additions & 0 deletions
116
src/ghosts.pandora.socializer/src/Views/Shared/_Post.cshtml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,116 @@ | ||
@model Socializer.Infrastructure.Post | ||
|
||
@{ | ||
var rnd = new Random(); | ||
|
||
Socializer.Infrastructure.User GetRandomUser() | ||
{ | ||
var u = new Socializer.Infrastructure.User(); | ||
var number = rnd.Next(1, 85); | ||
u.Name = Faker.Internet.UserName(); | ||
u.Avatar = $"/u/{u.Name}/avatar"; | ||
if (rnd.Next(1, 3) > 1) | ||
u.Name = Faker.Name.FullName(); | ||
return u; | ||
} | ||
|
||
var post = Model; | ||
|
||
<div class="ui-block"> | ||
<article class="hentry post"> | ||
<div class="post__author author vcard inline-items"> | ||
<img loading="lazy" src="/u/@post.User/avatar" alt="author" width="42" height="42"> | ||
<div class="author-date"> | ||
<a class="h6 post__author-name fn" href="/u/@post.User">@post.User</a> shared a <a href="/@post.Id">link</a> | ||
<div class="post__date"> | ||
<time class="published" datetime="@post.CreatedUtc"> | ||
@post.CreatedUtc | ||
</time> | ||
</div> | ||
</div> | ||
<div class="more"> | ||
<svg class="olymp-three-dots-icon"> | ||
<use xlink:href="#olymp-three-dots-icon"></use> | ||
</svg> | ||
<ul class="more-dropdown"> | ||
<li> | ||
<a href="#">Edit Post</a> | ||
</li> | ||
<li> | ||
<a href="#">Delete Post</a> | ||
</li> | ||
<li> | ||
<a href="#">Turn Off Notifications</a> | ||
</li> | ||
<li> | ||
<a href="#">Select as Featured</a> | ||
</li> | ||
</ul> | ||
</div> | ||
</div> | ||
|
||
@Html.Raw(post.Message) | ||
|
||
<div class="post-additional-info inline-items"> | ||
<a href="#" class="post-add-icon inline-items"> | ||
<svg class="olymp-heart-icon"> | ||
<use xlink:href="#olymp-heart-icon"></use> | ||
</svg> | ||
<span>18</span> | ||
</a> | ||
<ul class="friends-harmonic"> | ||
@{ | ||
for (var i = 1; i < rnd.Next(2, 16); i++) | ||
{ | ||
var img = $"/img/friend-harmonic{i}.webp"; | ||
<li> | ||
<a href="#"> | ||
<img loading="lazy" src="@img" alt="friend" width="28" height="28"> | ||
</a> | ||
</li> | ||
} | ||
} | ||
</ul> | ||
<div class="names-people-likes"> | ||
@{ | ||
var u = GetRandomUser(); | ||
<span><a href="/u/@u.Name">@u.Name</a> and <br/>@rnd.Next(1, 900) more liked this</span> | ||
} | ||
</div> | ||
<div class="comments-shared"> | ||
<a href="#" class="post-add-icon inline-items"> | ||
<svg class="olymp-speech-balloon-icon"> | ||
<use xlink:href="#olymp-speech-balloon-icon"></use> | ||
</svg> | ||
|
||
<span>0</span> | ||
</a> | ||
<a href="#" class="post-add-icon inline-items"> | ||
<svg class="olymp-share-icon"> | ||
<use xlink:href="#olymp-share-icon"></use> | ||
</svg> | ||
|
||
<span>16</span> | ||
</a> | ||
</div> | ||
</div> | ||
<div class="control-block-button post-control-button"> | ||
<a href="#" class="btn btn-control"> | ||
<svg class="olymp-like-post-icon"> | ||
<use xlink:href="#olymp-like-post-icon"></use> | ||
</svg> | ||
</a> | ||
<a href="#" class="btn btn-control"> | ||
<svg class="olymp-comments-post-icon"> | ||
<use xlink:href="#olymp-comments-post-icon"></use> | ||
</svg> | ||
</a> | ||
<a href="#" class="btn btn-control"> | ||
<svg class="olymp-share-icon"> | ||
<use xlink:href="#olymp-share-icon"></use> | ||
</svg> | ||
</a> | ||
</div> | ||
</article> | ||
</div> | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters