]> Untitled Git - lemmy-ui.git/commitdiff
Add clases and ID's to post form/listing
authorZetaphor <zetaphor@hey.com>
Fri, 16 Jun 2023 17:12:07 +0000 (14:12 -0300)
committerZetaphor <zetaphor@hey.com>
Fri, 16 Jun 2023 17:12:07 +0000 (14:12 -0300)
src/shared/components/post/create-post.tsx
src/shared/components/post/post-listing.tsx

index c7597917740486cd58eae285e54232887737b893..baa7b45ff3f778f3815af9853f24787889e9722c 100644 (file)
@@ -166,7 +166,10 @@ export class CreatePost extends Component<
           </h5>
         ) : (
           <div className="row">
-            <div className="col-12 col-lg-6 offset-lg-3 mb-4">
+            <div
+              id="createPostForm"
+              className="col-12 col-lg-6 offset-lg-3 mb-4"
+            >
               <h5>{i18n.t("create_post")}</h5>
               <PostForm
                 onCreate={this.handlePostCreate}
index 60e188a33b77c942ba5e9f33cdceb29a8e07e6bb..23ae3892b4c2d706e0fd15acd03b06eb38307571 100644 (file)
@@ -230,7 +230,7 @@ export class PostListing extends Component<PostListingProps, PostListingState> {
   body() {
     const body = this.postView.post.body;
     return body ? (
-      <div className="col-12 card my-2 p-2">
+      <div id="postContent" className="col-12 card my-2 p-2">
         {this.state.viewSource ? (
           <pre>{body}</pre>
         ) : (
@@ -464,7 +464,7 @@ export class PostListing extends Component<PostListingProps, PostListingState> {
         </button>
         {showScores() ? (
           <div
-            className={`unselectable pointer font-weight-bold text-muted px-1`}
+            className={`unselectable pointer font-weight-bold text-muted px-1 post-score`}
             data-tippy-content={this.pointsTippy}
           >
             {numToSI(this.postView.counts.score)}
@@ -1398,7 +1398,7 @@ export class PostListing extends Component<PostListingProps, PostListingState> {
       <>
         {/* The mobile view*/}
         <div className="d-block d-sm-none">
-          <div className="row">
+          <div className="row post-container">
             <div className="col-12">
               {this.createdLine()}
 
@@ -1418,9 +1418,9 @@ export class PostListing extends Component<PostListingProps, PostListingState> {
 
         {/* The larger view*/}
         <div className="d-none d-sm-block">
-          <div className="row">
+          <div className="row post-container">
             {!this.props.viewOnly && this.voteBar()}
-            <div className="col-sm-2 pr-0">
+            <div className="col-sm-2 pr-0 post-media">
               <div className="">{this.thumbnail()}</div>
             </div>
             <div className="col-12 col-sm-9">