public static Frame Comment_Grader_On_The_Answer_Frame(List <Plugins> plugins) { var inside_View = Structure_StackLayout.Inside_Frame_StackLayout(); var theme = Structure_Label.Theme_Label("Отзыв в виде комментария"); inside_View.Children.Add(theme); //данный способ не хороший, стоит сделать через Core_comment_get_comments foreach (var item in plugins) { if (item.type == "comments") { foreach (var item_ in item.editorfields) { var comment = Structure_Label.Tag_Label(item_.text, Color.Gray, 16); inside_View.Children.Add(comment); } } } var inside_Frame = Inside_Frame(inside_View); var view = Structure_StackLayout.View_Frame(); view.Children.Add(inside_Frame); var view_Frame = View_Frame(view); return(view_Frame); }
public static Frame Theme_And_Description_Frame(string intro) { var inside_View = Structure_StackLayout.Inside_Frame_StackLayout(); var theme_and_description_label = Structure_Label.Tag_Label( intro, Color.Black, 16); inside_View.Children.Add(theme_and_description_label); var inside_Frame = Inside_Frame(inside_View); var view = Structure_StackLayout.View_Frame(); view.Children.Add(inside_Frame); var view_Frame = View_Frame(view); return(view_Frame); }
public static Frame Grade_In_Journal_Frame(string submission_grade) { var theme = Structure_Label.Theme_Label("Текущая оценка в журнале"); var grade = Structure_Label.Tag_Label( submission_grade, Color.Gray, 16); var inside_View = Structure_StackLayout.Inside_Frame_StackLayout(); inside_View.Children.Add(theme); inside_View.Children.Add(grade); var inside_Frame = Inside_Frame(inside_View); var view = Structure_StackLayout.View_Frame(); view.Children.Add(inside_Frame); var view_Frame = View_Frame(view); return(view_Frame); }
public static Frame Comment_on_the_answer_frame(Comment comment) { var inside_View = Structure_StackLayout.Inside_Frame_StackLayout(); var commentatorView = Structure_StackLayout.Inside_Frame_View_Orientation(StackOrientation.Horizontal); var urlImage = Function.Take_Image_Url_From_String(comment.avatar); var profile_image = Structure_Image.Image_Profile(urlImage); commentatorView.Children.Add(profile_image); var commentatorInfoView = Structure_StackLayout.Inside_Frame_StackLayout(); var nameOfСommentator = Structure_Label.Theme_Label(comment.fullname); commentatorInfoView.Children.Add(nameOfСommentator); var textDate = Function.Text_Unix_Time_In_Date_Time( comment.timecreated, "d MMMM yyyy г., HH:mm"); var dateOfComment = Structure_Label.Description_Label(textDate); commentatorInfoView.Children.Add(dateOfComment); commentatorView.Children.Add(commentatorInfoView); var commentText = Structure_Label.Tag_Label(comment.content, Color.Black, 18); inside_View.Children.Add(commentatorView); inside_View.Children.Add(commentText); var inside_Frame = Inside_Frame(inside_View); var view = Structure_StackLayout.View_Frame(); view.Children.Add(inside_Frame); var view_Frame = View_Frame(view); return(view_Frame); }
public static Frame Cut_Off_Date_Frame(long unixTime) { var text = "Это назначение будет приниматься с <strong>" + Function.Text_Unix_Time_In_Date_Time( unixTime, "d MMMM yyyy г., HH:mm" + "</strong>" ); var theme_and_time = Structure_Label.Tag_Label( text, Color.Black, 18); var inside_View = Structure_StackLayout.Inside_Frame_StackLayout(); inside_View.Children.Add(theme_and_time); var inside_Frame = Inside_Frame(inside_View); var view = Structure_StackLayout.View_Frame(); view.Children.Add(inside_Frame); var view_Frame = View_Frame(view); return(view_Frame); }
public static Frame Answer_comments_frame(List <Editorfield> comments) { var inside_View = Structure_StackLayout.Inside_Frame_StackLayout(); var theme = Structure_Label.Theme_Label("Ответ в виде комментария"); inside_View.Children.Add(theme); foreach (var item in comments) { var comment_text_label = Structure_Label.Tag_Label(item.text, Color.Gray, 16); inside_View.Children.Add(comment_text_label); } var inside_Frame = Inside_Frame(inside_View); var view = Structure_StackLayout.View_Frame(); view.Children.Add(inside_Frame); var view_Frame = View_Frame(view); return(view_Frame); }