Timeline issue/pr (#1201)

Closes #953

Co-authored-by: M M Arif <mmarif@swatian.com>
Co-authored-by: 6543 <6543@obermui.de>
Reviewed-on: https://codeberg.org/gitnex/GitNex/pulls/1201
Reviewed-by: qwerty287 <qwerty287@noreply.codeberg.org>
This commit is contained in:
M M Arif 2022-09-14 20:40:44 +02:00
parent 3288fdbf3c
commit 8c1b07c2c8
91 changed files with 2017 additions and 667 deletions

View File

@ -7,12 +7,12 @@ pipeline:
regex: " \\\\* \\\\@author [\\\\S\\\\s]+"
must_contain: true
style:
image: qwerty287/woodpecker-intellij-formatter
group: check
settings:
file_pattern: "*.java"
path: "app/"
#style:
#image: qwerty287/woodpecker-intellij-formatter
#group: check
# settings:
#file_pattern: "*.java"
#path: "app/"
test:
image: alvrme/alpine-android:android-31-jdk11

View File

@ -17,7 +17,11 @@ import org.mian.gitnex.database.api.BaseApi;
import org.mian.gitnex.database.api.UserAccountsApi;
import org.mian.gitnex.database.models.UserAccount;
import org.mian.gitnex.databinding.ActivityAddNewAccountBinding;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.PathsHelper;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.UrlHelper;
import org.mian.gitnex.helpers.Version;
import org.mian.gitnex.structs.Protocol;
import java.net.URI;
import java.util.Objects;

View File

@ -10,7 +10,11 @@ import com.amrdeveloper.codeview.Code;
import org.apache.commons.lang3.EnumUtils;
import org.mian.gitnex.R;
import org.mian.gitnex.databinding.ActivityCodeEditorBinding;
import org.mian.gitnex.helpers.codeeditor.*;
import org.mian.gitnex.helpers.codeeditor.CustomCodeViewAdapter;
import org.mian.gitnex.helpers.codeeditor.LanguageManager;
import org.mian.gitnex.helpers.codeeditor.LanguageName;
import org.mian.gitnex.helpers.codeeditor.SourcePositionListener;
import org.mian.gitnex.helpers.codeeditor.ThemeName;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

View File

@ -15,7 +15,12 @@ import androidx.activity.result.ActivityResultLauncher;
import androidx.activity.result.contract.ActivityResultContracts;
import androidx.annotation.NonNull;
import org.apache.commons.io.FilenameUtils;
import org.gitnex.tea4j.v2.models.*;
import org.gitnex.tea4j.v2.models.Branch;
import org.gitnex.tea4j.v2.models.CreateFileOptions;
import org.gitnex.tea4j.v2.models.DeleteFileOptions;
import org.gitnex.tea4j.v2.models.FileDeleteResponse;
import org.gitnex.tea4j.v2.models.FileResponse;
import org.gitnex.tea4j.v2.models.UpdateFileOptions;
import org.mian.gitnex.R;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.databinding.ActivityCreateFileBinding;

View File

@ -12,7 +12,11 @@ import android.widget.ArrayAdapter;
import android.widget.TextView;
import androidx.annotation.NonNull;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import org.gitnex.tea4j.v2.models.*;
import org.gitnex.tea4j.v2.models.CreateIssueOption;
import org.gitnex.tea4j.v2.models.Issue;
import org.gitnex.tea4j.v2.models.Label;
import org.gitnex.tea4j.v2.models.Milestone;
import org.gitnex.tea4j.v2.models.User;
import org.mian.gitnex.R;
import org.mian.gitnex.actions.AssigneesActions;
import org.mian.gitnex.actions.LabelsActions;
@ -28,7 +32,12 @@ import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.Constants;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.contexts.RepositoryContext;
import java.util.*;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Date;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Objects;
import retrofit2.Call;
import retrofit2.Callback;

View File

@ -11,7 +11,11 @@ import android.widget.ImageView;
import android.widget.TextView;
import androidx.annotation.NonNull;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import org.gitnex.tea4j.v2.models.*;
import org.gitnex.tea4j.v2.models.Branch;
import org.gitnex.tea4j.v2.models.CreatePullRequestOption;
import org.gitnex.tea4j.v2.models.Label;
import org.gitnex.tea4j.v2.models.Milestone;
import org.gitnex.tea4j.v2.models.PullRequest;
import org.mian.gitnex.R;
import org.mian.gitnex.actions.LabelsActions;
import org.mian.gitnex.adapters.LabelsListAdapter;
@ -22,7 +26,12 @@ import org.mian.gitnex.fragments.PullRequestsFragment;
import org.mian.gitnex.helpers.Constants;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.contexts.RepositoryContext;
import java.util.*;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Date;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Objects;
import retrofit2.Call;
import retrofit2.Callback;

View File

@ -8,9 +8,18 @@ import android.util.Log;
import android.view.MotionEvent;
import android.view.View;
import android.view.inputmethod.InputMethodManager;
import android.widget.*;
import android.widget.ArrayAdapter;
import android.widget.AutoCompleteTextView;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.EditText;
import android.widget.ImageView;
import androidx.annotation.NonNull;
import org.gitnex.tea4j.v2.models.*;
import org.gitnex.tea4j.v2.models.Branch;
import org.gitnex.tea4j.v2.models.CreateReleaseOption;
import org.gitnex.tea4j.v2.models.CreateTagOption;
import org.gitnex.tea4j.v2.models.Release;
import org.gitnex.tea4j.v2.models.Tag;
import org.mian.gitnex.R;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.databinding.ActivityCreateReleaseBinding;

View File

@ -7,7 +7,12 @@ import android.os.Looper;
import android.util.Log;
import android.view.View;
import android.view.inputmethod.InputMethodManager;
import android.widget.*;
import android.widget.ArrayAdapter;
import android.widget.AutoCompleteTextView;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.EditText;
import android.widget.ImageView;
import androidx.annotation.NonNull;
import org.gitnex.tea4j.v2.models.CreateRepoOption;
import org.gitnex.tea4j.v2.models.Organization;

View File

@ -9,7 +9,11 @@ import android.util.Log;
import android.view.View;
import androidx.annotation.NonNull;
import org.apache.commons.lang3.StringUtils;
import org.gitnex.tea4j.v2.models.*;
import org.gitnex.tea4j.v2.models.ContentsResponse;
import org.gitnex.tea4j.v2.models.Organization;
import org.gitnex.tea4j.v2.models.PullRequest;
import org.gitnex.tea4j.v2.models.Repository;
import org.gitnex.tea4j.v2.models.User;
import org.mian.gitnex.R;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.database.api.BaseApi;

View File

@ -11,7 +11,12 @@ import android.util.Log;
import android.view.MotionEvent;
import android.view.View;
import android.view.inputmethod.InputMethodManager;
import android.widget.*;
import android.widget.ArrayAdapter;
import android.widget.AutoCompleteTextView;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.TextView;
import androidx.annotation.NonNull;
import org.gitnex.tea4j.v2.models.EditIssueOption;
import org.gitnex.tea4j.v2.models.Issue;
@ -28,7 +33,12 @@ import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.contexts.IssueContext;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.*;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Date;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Objects;
import retrofit2.Call;
import retrofit2.Callback;

View File

@ -16,7 +16,6 @@ import android.view.MenuItem;
import android.view.View;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;
import android.widget.ScrollView;
import androidx.activity.result.ActivityResultLauncher;
import androidx.activity.result.contract.ActivityResultContracts;
@ -94,7 +93,7 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
private String repoName;
private int issueIndex;
private String issueCreator;
private IssueContext issue;
public IssueContext issue;
private LabelsListAdapter labelsAdapter;
private AssigneesListAdapter assigneesAdapter;
private List<Integer> currentLabelsIds = new ArrayList<>();
@ -124,6 +123,7 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
}
}
});
private int page = 1;
@Override
public void onCreate(Bundle savedInstanceState) {
@ -164,10 +164,11 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
viewBinding.pullToRefresh.setOnRefreshListener(() -> new Handler(Looper.getMainLooper()).postDelayed(() -> {
page = 1;
viewBinding.pullToRefresh.setRefreshing(false);
issueCommentsModel.loadIssueComments(repoOwner, repoName, issueIndex, ctx);
issueCommentsModel.loadIssueComments(repoOwner, repoName, issueIndex, ctx, null);
}, 500));
}, 50));
Typeface myTypeface = AppUtil.getTypeface(this);
viewBinding.toolbarTitle.setTypeface(myTypeface);
@ -459,7 +460,7 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
viewBinding.scrollViewComments.post(() -> {
issueCommentsModel.loadIssueComments(repoOwner, repoName, issueIndex, ctx);
issueCommentsModel.loadIssueComments(repoOwner, repoName, issueIndex, ctx, null);
commentEdited = false;
});
}
@ -482,21 +483,37 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
issueCommentsModel.getIssueCommentList(owner, repo, index, ctx).observe(this, issueCommentsMain -> {
assert issueCommentsMain != null;
Bundle bundle = new Bundle();
bundle.putString("repoOwner", repoOwner);
bundle.putString("repoName", repoName);
bundle.putInt("issueNumber", issueIndex);
adapter = new IssueCommentsAdapter(ctx, bundle, issueCommentsMain, getSupportFragmentManager(), this::onResume, issue);
adapter.setLoadMoreListener(new IssueCommentsAdapter.OnLoadMoreListener() {
@Override
public void onLoadMore() {
page += 1;
issueCommentsModel.loadMoreIssueComments(owner, repo, index, ctx, page, adapter);
viewBinding.progressBar.setVisibility(View.VISIBLE);
}
@Override
public void onLoadFinished() {
viewBinding.progressBar.setVisibility(View.GONE);
}
});
adapter.notifyDataChanged();
viewBinding.recyclerView.setAdapter(adapter);
viewBinding.progressBar.setVisibility(View.GONE);
});
}
private void getSingleIssue(String repoOwner, String repoName, int issueIndex) {
if(issue.hasIssue()) {
viewBinding.progressBar.setVisibility(View.GONE);
getSubscribed();
@ -570,6 +587,7 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
}
private void initWithIssue() {
if(!issue.getRepository().hasRepository()) {
getRepoInfo();
}
@ -663,12 +681,18 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
});
}
Markdown.render(ctx, EmojiParser.parseToUnicode(cleanIssueDescription), viewBinding.issueDescription, issue.getRepository());
viewBinding.author.setText(issue.getIssue().getUser().getLogin());
RelativeLayout.LayoutParams paramsDesc = (RelativeLayout.LayoutParams) viewBinding.issueDescription.getLayoutParams();
if(!cleanIssueDescription.equals("")) {
viewBinding.issueDescription.setVisibility(View.VISIBLE);
Markdown.render(ctx, EmojiParser.parseToUnicode(cleanIssueDescription), viewBinding.issueDescription, issue.getRepository());
}
else {
viewBinding.issueDescription.setVisibility(View.GONE);
}
LinearLayout.LayoutParams params1 = new LinearLayout.LayoutParams(80, 80);
params1.setMargins(15, 0, 0, 0);
LinearLayout.LayoutParams paramsAssignees = new LinearLayout.LayoutParams(64, 64);
paramsAssignees.setMargins(15, 0, 0, 0);
if(issue.getIssue().getAssignees() != null) {
@ -678,11 +702,11 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
ImageView assigneesView = new ImageView(ctx);
PicassoService.getInstance(ctx).get().load(issue.getIssue().getAssignees().get(i).getAvatarUrl()).placeholder(R.drawable.loader_animated).transform(new RoundedTransformation(48, 0)).resize(96, 96)
PicassoService.getInstance(ctx).get().load(issue.getIssue().getAssignees().get(i).getAvatarUrl()).placeholder(R.drawable.loader_animated).transform(new RoundedTransformation(36, 0)).resize(72, 72)
.centerCrop().into(assigneesView);
viewBinding.frameAssignees.addView(assigneesView);
assigneesView.setLayoutParams(params1);
assigneesView.setLayoutParams(paramsAssignees);
int finalI = i;
@ -699,17 +723,6 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
return true;
});
}
/*if(!issue.getIssue().getAssignees().get(i).getFull_name().equals("")) {
assigneesView.setOnClickListener(
new ClickListener(getString(R.string.assignedTo, issue.getIssue().getAssignees().get(i).getFull_name()), ctx));
}
else {
assigneesView.setOnClickListener(
new ClickListener(getString(R.string.assignedTo, issue.getIssue().getAssignees().get(i).getLogin()), ctx));
}*/
}
}
else {
@ -717,10 +730,10 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
viewBinding.assigneesScrollView.setVisibility(View.GONE);
}
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.WRAP_CONTENT, LinearLayout.LayoutParams.WRAP_CONTENT);
params.setMargins(0, 0, 15, 0);
LinearLayout.LayoutParams paramsLabels = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.WRAP_CONTENT, LinearLayout.LayoutParams.WRAP_CONTENT);
paramsLabels.setMargins(0, 0, 15, 0);
if(issue.getIssue().getLabels() != null) {
if(issue.getIssue().getLabels().size() > 0) {
viewBinding.labelsScrollView.setVisibility(View.VISIBLE);
@ -733,7 +746,7 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
ImageView labelsView = new ImageView(ctx);
viewBinding.frameLabels.setOrientation(LinearLayout.HORIZONTAL);
viewBinding.frameLabels.setGravity(Gravity.START | Gravity.TOP);
labelsView.setLayoutParams(params);
labelsView.setLayoutParams(paramsLabels);
int height = AppUtil.getPixelsFromDensity(ctx, 20);
int textSize = AppUtil.getPixelsFromScaledDensity(ctx, 12);
@ -787,27 +800,6 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
viewBinding.issueModified.setVisibility(View.INVISIBLE);
}
if((issue.getIssue().getDueDate() == null && issue.getIssue().getMilestone() == null) && issue.getIssue().getAssignees() != null) {
paramsDesc.setMargins(0, 35, 0, 0);
viewBinding.issueDescription.setLayoutParams(paramsDesc);
}
else if(issue.getIssue().getDueDate() == null && issue.getIssue().getMilestone() == null) {
paramsDesc.setMargins(0, 55, 0, 0);
viewBinding.issueDescription.setLayoutParams(paramsDesc);
}
else if(issue.getIssue().getAssignees() == null) {
paramsDesc.setMargins(0, 35, 0, 0);
viewBinding.issueDescription.setLayoutParams(paramsDesc);
}
else {
paramsDesc.setMargins(0, 15, 0, 0);
viewBinding.issueDescription.setLayoutParams(paramsDesc);
}
viewBinding.issueCreatedTime.setText(TimeHelper.formatTime(issue.getIssue().getCreatedAt(), locale, timeFormat, ctx));
viewBinding.issueCreatedTime.setVisibility(View.VISIBLE);
@ -842,17 +834,6 @@ public class IssueDetailActivity extends BaseActivity implements LabelsListAdapt
viewBinding.milestoneFrame.setVisibility(View.GONE);
}
/*if(!issue.getIssue().getUser().getFull_name().equals("")) {
viewBinding.assigneeAvatar.setOnClickListener(
new ClickListener(ctx.getResources().getString(R.string.issueCreator) + issue.getIssue().getUser().getFull_name(), ctx));
}
else {
viewBinding.assigneeAvatar.setOnClickListener(
new ClickListener(ctx.getResources().getString(R.string.issueCreator) + issue.getIssue().getUser().getLogin(), ctx));
}*/
}
private void getPullRequest() {

View File

@ -3,17 +3,30 @@ package org.mian.gitnex.activities;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.*;
import android.widget.ArrayAdapter;
import android.widget.AutoCompleteTextView;
import android.widget.Button;
import android.widget.EditText;
import android.widget.RadioGroup;
import androidx.annotation.NonNull;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import org.gitnex.tea4j.v2.models.*;
import org.gitnex.tea4j.v2.models.AccessToken;
import org.gitnex.tea4j.v2.models.CreateAccessTokenOption;
import org.gitnex.tea4j.v2.models.GeneralAPISettings;
import org.gitnex.tea4j.v2.models.ServerVersion;
import org.gitnex.tea4j.v2.models.User;
import org.mian.gitnex.R;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.database.api.BaseApi;
import org.mian.gitnex.database.api.UserAccountsApi;
import org.mian.gitnex.database.models.UserAccount;
import org.mian.gitnex.databinding.ActivityLoginBinding;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.NetworkStatusObserver;
import org.mian.gitnex.helpers.PathsHelper;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.UrlHelper;
import org.mian.gitnex.helpers.Version;
import org.mian.gitnex.structs.Protocol;
import java.net.URI;
import java.nio.charset.StandardCharsets;

View File

@ -34,8 +34,26 @@ import org.mian.gitnex.database.api.BaseApi;
import org.mian.gitnex.database.api.UserAccountsApi;
import org.mian.gitnex.database.models.UserAccount;
import org.mian.gitnex.databinding.ActivityMainBinding;
import org.mian.gitnex.fragments.*;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.fragments.AdministrationFragment;
import org.mian.gitnex.fragments.BottomSheetDraftsFragment;
import org.mian.gitnex.fragments.BottomSheetMyIssuesFilterFragment;
import org.mian.gitnex.fragments.DraftsFragment;
import org.mian.gitnex.fragments.ExploreFragment;
import org.mian.gitnex.fragments.MostVisitedReposFragment;
import org.mian.gitnex.fragments.MyIssuesFragment;
import org.mian.gitnex.fragments.MyProfileFragment;
import org.mian.gitnex.fragments.MyRepositoriesFragment;
import org.mian.gitnex.fragments.NotificationsFragment;
import org.mian.gitnex.fragments.OrganizationsFragment;
import org.mian.gitnex.fragments.RepositoriesFragment;
import org.mian.gitnex.fragments.SettingsFragment;
import org.mian.gitnex.fragments.StarredRepositoriesFragment;
import org.mian.gitnex.helpers.AlertDialogs;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ChangeLog;
import org.mian.gitnex.helpers.ColorInverter;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.structs.BottomSheetListener;
import org.mian.gitnex.structs.FragmentRefreshListener;
import java.util.ArrayList;

View File

@ -19,7 +19,12 @@ import com.google.android.material.tabs.TabLayoutMediator;
import org.mian.gitnex.R;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.fragments.BottomSheetUserProfileFragment;
import org.mian.gitnex.fragments.profile.*;
import org.mian.gitnex.fragments.profile.DetailFragment;
import org.mian.gitnex.fragments.profile.FollowersFragment;
import org.mian.gitnex.fragments.profile.FollowingFragment;
import org.mian.gitnex.fragments.profile.OrganizationsFragment;
import org.mian.gitnex.fragments.profile.RepositoriesFragment;
import org.mian.gitnex.fragments.profile.StarredRepositoriesFragment;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.structs.BottomSheetListener;

View File

@ -6,7 +6,12 @@ import android.content.Intent;
import android.content.res.ColorStateList;
import android.graphics.Typeface;
import android.os.Bundle;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import android.widget.TextView;
import androidx.activity.result.ActivityResultLauncher;
@ -21,10 +26,27 @@ import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import com.google.android.material.progressindicator.LinearProgressIndicator;
import com.google.android.material.tabs.TabLayout;
import com.google.android.material.tabs.TabLayoutMediator;
import org.gitnex.tea4j.v2.models.*;
import org.gitnex.tea4j.v2.models.Branch;
import org.gitnex.tea4j.v2.models.Milestone;
import org.gitnex.tea4j.v2.models.Organization;
import org.gitnex.tea4j.v2.models.Repository;
import org.gitnex.tea4j.v2.models.WatchInfo;
import org.mian.gitnex.R;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.fragments.*;
import org.mian.gitnex.fragments.BottomSheetIssuesFilterFragment;
import org.mian.gitnex.fragments.BottomSheetMilestonesFilterFragment;
import org.mian.gitnex.fragments.BottomSheetPullRequestFilterFragment;
import org.mian.gitnex.fragments.BottomSheetReleasesTagsFragment;
import org.mian.gitnex.fragments.BottomSheetRepoFragment;
import org.mian.gitnex.fragments.CollaboratorsFragment;
import org.mian.gitnex.fragments.FilesFragment;
import org.mian.gitnex.fragments.IssuesFragment;
import org.mian.gitnex.fragments.LabelsFragment;
import org.mian.gitnex.fragments.MilestonesFragment;
import org.mian.gitnex.fragments.PullRequestsFragment;
import org.mian.gitnex.fragments.ReleasesFragment;
import org.mian.gitnex.fragments.RepoInfoFragment;
import org.mian.gitnex.fragments.WikiFragment;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.contexts.RepositoryContext;
@ -85,6 +107,8 @@ public class RepoDetailActivity extends BaseActivity implements BottomSheetListe
private FragmentRefreshListener fragmentRefreshListenerFilterIssuesByMilestone;
private FragmentRefreshListener fragmentRefreshListenerReleases;
private Dialog progressDialog;
private MaterialAlertDialogBuilder materialAlertDialogBuilder;
private Intent intentWiki;
private final ActivityResultLauncher<Intent> createReleaseLauncher = registerForActivityResult(new ActivityResultContracts.StartActivityForResult(), result -> {
if(result.getResultCode() == 201) {
assert result.getData() != null;
@ -97,8 +121,6 @@ public class RepoDetailActivity extends BaseActivity implements BottomSheetListe
}
}
});
private MaterialAlertDialogBuilder materialAlertDialogBuilder;
private Intent intentWiki;
@Override
public void onCreate(Bundle savedInstanceState) {
@ -143,7 +165,7 @@ public class RepoDetailActivity extends BaseActivity implements BottomSheetListe
}
@Override
public boolean onCreateOptionsMenu(Menu menu) {
public boolean onCreateOptionsMenu(@NonNull Menu menu) {
MenuInflater inflater = getMenuInflater();
inflater.inflate(R.menu.repo_dotted_menu, menu);
@ -857,6 +879,4 @@ public class RepoDetailActivity extends BaseActivity implements BottomSheetListe
}
}
}

View File

@ -11,6 +11,7 @@ import android.widget.TextView;
import androidx.annotation.NonNull;
import androidx.core.text.HtmlCompat;
import androidx.recyclerview.widget.RecyclerView;
import com.google.android.material.card.MaterialCardView;
import com.vdurmont.emoji.EmojiParser;
import org.gitnex.tea4j.v2.models.Commit;
import org.mian.gitnex.R;
@ -99,6 +100,8 @@ public class CommitsAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder
ImageView commitAuthorAvatar;
ImageView commitCommitterAvatar;
TextView commitSha;
MaterialCardView commitCommitterAvatarFrame;
MaterialCardView commitAuthorAvatarFrame;
CommitsHolder(View itemView) {
@ -111,7 +114,8 @@ public class CommitsAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder
commitAuthorAvatar = itemView.findViewById(R.id.commitAuthorAvatar);
commitCommitterAvatar = itemView.findViewById(R.id.commitCommitterAvatar);
commitSha = itemView.findViewById(R.id.commitSha);
commitCommitterAvatarFrame = itemView.findViewById(R.id.commitCommitterAvatarFrame);
commitAuthorAvatarFrame = itemView.findViewById(R.id.commitAuthorAvatarFrame);
}
void bindData(Commit commitsModel) {
@ -135,7 +139,7 @@ public class CommitsAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder
if(commitsModel.getAuthor() != null && commitsModel.getAuthor().getAvatarUrl() != null && !commitsModel.getAuthor().getAvatarUrl().isEmpty()) {
commitAuthorAvatar.setVisibility(View.VISIBLE);
commitAuthorAvatarFrame.setVisibility(View.VISIBLE);
int imgRadius = AppUtil.getPixelsFromDensity(context, 60);
@ -145,13 +149,13 @@ public class CommitsAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder
}
else {
commitAuthorAvatar.setImageDrawable(null);
commitAuthorAvatar.setVisibility(View.GONE);
commitAuthorAvatarFrame.setVisibility(View.GONE);
}
if(commitsModel.getCommitter() != null && (commitsModel.getAuthor() == null || !commitsModel.getAuthor().getLogin().equals(commitsModel.getCommitter().getLogin())) && commitsModel.getCommitter()
.getAvatarUrl() != null && !commitsModel.getCommitter().getAvatarUrl().isEmpty()) {
commitCommitterAvatar.setVisibility(View.VISIBLE);
commitCommitterAvatarFrame.setVisibility(View.VISIBLE);
int imgRadius = AppUtil.getPixelsFromDensity(context, 60);
@ -161,7 +165,7 @@ public class CommitsAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder
}
else {
commitCommitterAvatar.setImageDrawable(null);
commitCommitterAvatar.setVisibility(View.GONE);
commitCommitterAvatarFrame.setVisibility(View.GONE);
}
commitSha.setText(commitsModel.getSha().substring(0, Math.min(commitsModel.getSha().length(), 10)));

View File

@ -15,6 +15,7 @@ import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;
import androidx.annotation.NonNull;
import androidx.core.content.ContextCompat;
import androidx.core.content.res.ResourcesCompat;
import androidx.core.text.HtmlCompat;
import androidx.recyclerview.widget.RecyclerView;
@ -24,7 +25,13 @@ import org.mian.gitnex.R;
import org.mian.gitnex.activities.IssueDetailActivity;
import org.mian.gitnex.activities.ProfileActivity;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ClickListener;
import org.mian.gitnex.helpers.ColorInverter;
import org.mian.gitnex.helpers.LabelWidthCalculator;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.contexts.IssueContext;
import org.mian.gitnex.helpers.contexts.RepositoryContext;
import org.ocpsoft.prettytime.PrettyTime;
@ -119,6 +126,7 @@ public class ExploreIssuesAdapter extends RecyclerView.Adapter<RecyclerView.View
private final LinearLayout frameLabels;
private final HorizontalScrollView labelsScrollViewDots;
private final LinearLayout frameLabelsDots;
private final ImageView commentIcon;
private Issue issue;
IssuesHolder(View itemView) {
@ -132,6 +140,7 @@ public class ExploreIssuesAdapter extends RecyclerView.Adapter<RecyclerView.View
frameLabels = itemView.findViewById(R.id.frameLabels);
labelsScrollViewDots = itemView.findViewById(R.id.labelsScrollViewDots);
frameLabelsDots = itemView.findViewById(R.id.frameLabelsDots);
commentIcon = itemView.findViewById(R.id.comment_icon);
new Handler().postDelayed(() -> {
@ -248,6 +257,11 @@ public class ExploreIssuesAdapter extends RecyclerView.Adapter<RecyclerView.View
labelsScrollViewWithText.setVisibility(View.GONE);
}
if(issue.getComments() > 15) {
commentIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_flame));
commentIcon.setColorFilter(context.getResources().getColor(R.color.releasePre, null));
}
switch(timeFormat) {
case "pretty": {
PrettyTime prettyTime = new PrettyTime(locale);

View File

@ -17,7 +17,11 @@ import com.amulyakhare.textdrawable.util.ColorGenerator;
import org.mian.gitnex.R;
import org.mian.gitnex.activities.RepoDetailActivity;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ClickListener;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.contexts.RepositoryContext;
import org.ocpsoft.prettytime.PrettyTime;
import java.text.DateFormat;

View File

@ -4,7 +4,11 @@ import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.*;
import android.widget.Filter;
import android.widget.Filterable;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;
import androidx.annotation.NonNull;
import androidx.appcompat.content.res.AppCompatResources;
import androidx.recyclerview.widget.RecyclerView;

View File

@ -5,29 +5,55 @@ import android.content.ClipData;
import android.content.ClipboardManager;
import android.content.Context;
import android.content.Intent;
import android.graphics.Color;
import android.graphics.Typeface;
import android.os.Bundle;
import android.os.Handler;
import android.text.Spannable;
import android.text.SpannableString;
import android.text.style.ImageSpan;
import android.view.Gravity;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.FrameLayout;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;
import android.widget.TextView;
import androidx.annotation.NonNull;
import androidx.core.content.ContextCompat;
import androidx.core.content.res.ResourcesCompat;
import androidx.core.text.HtmlCompat;
import androidx.fragment.app.FragmentManager;
import androidx.recyclerview.widget.RecyclerView;
import com.amulyakhare.textdrawable.TextDrawable;
import com.google.android.material.bottomsheet.BottomSheetDialog;
import com.google.android.material.card.MaterialCardView;
import com.vdurmont.emoji.EmojiParser;
import org.gitnex.tea4j.v2.models.Comment;
import org.apache.commons.lang3.StringUtils;
import org.gitnex.tea4j.v2.models.TimelineComment;
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
import org.mian.gitnex.R;
import org.mian.gitnex.activities.BaseActivity;
import org.mian.gitnex.activities.CommitDetailActivity;
import org.mian.gitnex.activities.IssueDetailActivity;
import org.mian.gitnex.activities.ProfileActivity;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.fragments.BottomSheetReplyFragment;
import org.mian.gitnex.fragments.IssuesFragment;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AlertDialogs;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ColorInverter;
import org.mian.gitnex.helpers.LabelWidthCalculator;
import org.mian.gitnex.helpers.Markdown;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.contexts.IssueContext;
import org.mian.gitnex.views.ReactionList;
import org.mian.gitnex.views.ReactionSpinner;
@ -41,18 +67,21 @@ import retrofit2.Callback;
* @author M M Arif
*/
public class IssueCommentsAdapter extends RecyclerView.Adapter<IssueCommentsAdapter.IssueCommentViewHolder> {
public class IssueCommentsAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder> {
private final Context context;
private final TinyDB tinyDB;
private final Bundle bundle;
private final List<Comment> issuesComments;
private final FragmentManager fragmentManager;
private final Runnable onInteractedListener;
private final Locale locale;
private final IssueContext issue;
private List<TimelineComment> issuesComments;
private OnLoadMoreListener loadMoreListener;
private boolean isLoading = false, isMoreDataAvailable = true, timelineLastView = false;
private Intent intent;
public IssueCommentsAdapter(Context ctx, Bundle bundle, List<Comment> issuesCommentsMain, FragmentManager fragmentManager, Runnable onInteractedListener, IssueContext issue) {
public IssueCommentsAdapter(Context ctx, Bundle bundle, List<TimelineComment> issuesCommentsMain, FragmentManager fragmentManager, Runnable onInteractedListener, IssueContext issue) {
this.context = ctx;
this.bundle = bundle;
@ -75,7 +104,7 @@ public class IssueCommentsAdapter extends RecyclerView.Adapter<IssueCommentsAdap
Call<Void> call = RetrofitClient.getApiInterface(ctx).issueDeleteComment(issue.getRepository().getOwner(), issue.getRepository().getName(), (long) commentId);
call.enqueue(new Callback<Void>() {
call.enqueue(new Callback<>() {
@Override
public void onResponse(@NonNull Call<Void> call, @NonNull retrofit2.Response<Void> response) {
@ -116,63 +145,47 @@ public class IssueCommentsAdapter extends RecyclerView.Adapter<IssueCommentsAdap
@NonNull
@Override
public IssueCommentsAdapter.IssueCommentViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
View v = LayoutInflater.from(parent.getContext()).inflate(R.layout.list_issue_comments, parent, false);
return new IssueCommentsAdapter.IssueCommentViewHolder(v);
public RecyclerView.ViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType) {
LayoutInflater inflater = LayoutInflater.from(context);
return new IssueCommentViewHolder(inflater.inflate(R.layout.list_issue_comments, parent, false));
}
@Override
public void onBindViewHolder(@NonNull IssueCommentsAdapter.IssueCommentViewHolder holder, int position) {
String timeFormat = tinyDB.getString("dateFormat", "pretty");
Comment issueComment = issuesComments.get(position);
int imgRadius = AppUtil.getPixelsFromDensity(context, 3);
holder.userLoginId = issueComment.getUser().getLogin();
holder.issueComment = issueComment;
holder.author.setText(issueComment.getUser().getLogin());
PicassoService.getInstance(context).get().load(issueComment.getUser().getAvatarUrl()).placeholder(R.drawable.loader_animated).transform(new RoundedTransformation(imgRadius, 0))
.resize(AppUtil.getPixelsFromDensity(context, 35), AppUtil.getPixelsFromDensity(context, 35)).centerCrop().into(holder.avatar);
Markdown.render(context, EmojiParser.parseToUnicode(issueComment.getBody()), holder.comment, issue.getRepository());
StringBuilder informationBuilder = null;
if(issueComment.getCreatedAt() != null) {
if(timeFormat.equals("pretty")) {
informationBuilder = new StringBuilder(TimeHelper.formatTime(issueComment.getCreatedAt(), locale, "pretty", context));
holder.information.setOnClickListener(v -> TimeHelper.customDateFormatForToastDateFormat(issueComment.getCreatedAt()));
}
else if(timeFormat.equals("normal")) {
informationBuilder = new StringBuilder(TimeHelper.formatTime(issueComment.getCreatedAt(), locale, "normal", context));
}
if(!issueComment.getCreatedAt().equals(issueComment.getUpdatedAt())) {
if(informationBuilder != null) {
informationBuilder.append(context.getString(R.string.colorfulBulletSpan)).append(context.getString(R.string.modifiedText));
}
}
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder holder, int position) {
if(position >= getItemCount() - 1 && isMoreDataAvailable && !isLoading && loadMoreListener != null) {
isLoading = true;
loadMoreListener.onLoadMore();
timelineLastView = true;
}
holder.information.setText(informationBuilder);
((IssueCommentsAdapter.IssueCommentViewHolder) holder).bindData(issuesComments.get(position));
}
Bundle bundle1 = new Bundle();
bundle1.putAll(bundle);
bundle1.putInt("commentId", Math.toIntExact(issueComment.getId()));
public void notifyDataChanged() {
notifyItemInserted(issuesComments.size());
isLoading = false;
loadMoreListener.onLoadFinished();
}
ReactionList reactionList = new ReactionList(context, bundle1);
public void setMoreDataAvailable(boolean moreDataAvailable) {
isMoreDataAvailable = moreDataAvailable;
if(!isMoreDataAvailable) {
loadMoreListener.onLoadFinished();
}
}
holder.commentReactionBadges.addView(reactionList);
reactionList.setOnReactionAddedListener(() -> {
public void setLoadMoreListener(OnLoadMoreListener loadMoreListener) {
this.loadMoreListener = loadMoreListener;
}
if(holder.commentReactionBadges.getVisibility() != View.VISIBLE) {
holder.commentReactionBadges.post(() -> holder.commentReactionBadges.setVisibility(View.VISIBLE));
}
});
public void updateList(List<TimelineComment> list) {
issuesComments = list;
notifyDataChanged();
}
@Override
public int getItemViewType(int position) {
return position;
}
@Override
@ -180,6 +193,12 @@ public class IssueCommentsAdapter extends RecyclerView.Adapter<IssueCommentsAdap
return issuesComments.size();
}
public interface OnLoadMoreListener {
void onLoadMore();
void onLoadFinished();
}
class IssueCommentViewHolder extends RecyclerView.ViewHolder {
private final ImageView avatar;
@ -187,8 +206,14 @@ public class IssueCommentsAdapter extends RecyclerView.Adapter<IssueCommentsAdap
private final TextView information;
private final RecyclerView comment;
private final LinearLayout commentReactionBadges;
private final MaterialCardView commentView;
private final RelativeLayout timelineView;
private final LinearLayout timelineData;
private final ImageView timelineIcon;
private String userLoginId;
private Comment issueComment;
private TimelineComment issueComment;
private final LinearLayout timelineDividerView;
private final FrameLayout timelineLine2;
private IssueCommentViewHolder(View view) {
@ -201,6 +226,14 @@ public class IssueCommentsAdapter extends RecyclerView.Adapter<IssueCommentsAdap
comment = view.findViewById(R.id.comment);
commentReactionBadges = view.findViewById(R.id.commentReactionBadges);
commentView = view.findViewById(R.id.comment_view);
timelineView = view.findViewById(R.id.timeline_view);
timelineData = view.findViewById(R.id.timeline_data);
timelineIcon = view.findViewById(R.id.timeline_icon);
timelineDividerView = view.findViewById(R.id.timeline_divider_view);
timelineLine2 = view.findViewById(R.id.timeline_line_2);
menu.setOnClickListener(v -> {
final String loginUid = ((BaseActivity) context).getAccount().getAccount().getUserName();
@ -325,7 +358,7 @@ public class IssueCommentsAdapter extends RecyclerView.Adapter<IssueCommentsAdap
});
commentMenuDelete.setOnClickListener(v1 -> {
deleteIssueComment(context, Math.toIntExact(issueComment.getId()), getAdapterPosition());
deleteIssueComment(context, Math.toIntExact(issueComment.getId()), getBindingAdapterPosition());
dialog.dismiss();
});
@ -347,6 +380,456 @@ public class IssueCommentsAdapter extends RecyclerView.Adapter<IssueCommentsAdap
}, 500);
}
void bindData(TimelineComment timelineComment) {
int fontSize = 14;
String timeFormat = tinyDB.getString("dateFormat", "pretty");
int imgRadius = AppUtil.getPixelsFromDensity(context, 3);
userLoginId = timelineComment.getUser().getLogin();
this.issueComment = timelineComment;
if(timelineLastView) {
//timelineLine2.setVisibility(View.GONE);
}
StringBuilder informationBuilder = null;
if(issueComment.getCreatedAt() != null) {
if(timeFormat.equals("pretty")) {
informationBuilder = new StringBuilder(TimeHelper.formatTime(issueComment.getCreatedAt(), locale, "pretty", context));
information.setOnClickListener(v -> TimeHelper.customDateFormatForToastDateFormat(issueComment.getCreatedAt()));
}
else if(timeFormat.equals("normal")) {
informationBuilder = new StringBuilder(TimeHelper.formatTime(issueComment.getCreatedAt(), locale, "normal", context));
}
if(!issueComment.getCreatedAt().equals(issueComment.getUpdatedAt())) {
if(informationBuilder != null) {
informationBuilder.append(context.getString(R.string.colorfulBulletSpan)).append(context.getString(R.string.modifiedText));
}
}
}
// label view in timeline
if(issueComment.getType().equalsIgnoreCase("label")) {
int color = Color.parseColor("#" + issueComment.getLabel().getColor());
int height = AppUtil.getPixelsFromDensity(context, 20);
int textSize = AppUtil.getPixelsFromScaledDensity(context, 12);
TextDrawable drawable = TextDrawable.builder().beginConfig().useFont(Typeface.DEFAULT).textColor(new ColorInverter().getContrastColor(color)).fontSize(textSize)
.width(LabelWidthCalculator.calculateLabelWidth(issueComment.getLabel().getName(), Typeface.DEFAULT, textSize, AppUtil.getPixelsFromDensity(context, 10))).height(height).endConfig()
.buildRoundRect(issueComment.getLabel().getName(), color, AppUtil.getPixelsFromDensity(context, 18));
TextView textView = new TextView(context);
String startText;
String endText = context.getString(R.string.timelineLabelEnd, informationBuilder);
if(issueComment.getBody().equals("")) {
startText = context.getString(R.string.timelineRemovedLabelStart, issueComment.getUser().getLogin());
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
else {
startText = context.getString(R.string.timelineAddedLabelStart, issueComment.getUser().getLogin());
}
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_tag));
SpannableString spannableString = new SpannableString(startText + " " + endText);
drawable.setBounds(0, 0, drawable.getIntrinsicWidth(), drawable.getIntrinsicHeight());
ImageSpan image = new ImageSpan(drawable);
new Handler().postDelayed(() -> {
spannableString.setSpan(image, startText.length(), startText.length() + 1, Spannable.SPAN_INCLUSIVE_EXCLUSIVE);
textView.setText(spannableString);
timelineData.addView(textView);
}, 250);
}
// pull/push/commit data view in timeline
else if(issueComment.getType().equalsIgnoreCase("pull_push")) {
TextView start = new TextView(context);
JSONObject commitsObj = null;
try {
commitsObj = new JSONObject(issueComment.getBody());
}
catch(JSONException ignored) {}
JSONArray commitsShaArray = null;
try {
commitsShaArray = Objects.requireNonNull(commitsObj).getJSONArray("commit_ids");
}
catch(JSONException ignored) {}
String commitText = context.getResources().getString(R.string.commits).toLowerCase();
if(Objects.requireNonNull(commitsShaArray).length() == 1) {
commitText = context.getResources().getString(R.string.commitText).toLowerCase();
}
String commitString = context.getString(R.string.timelineAddedCommit, issueComment.getUser().getLogin()) + commitText + " " + informationBuilder;
start.setText(HtmlCompat.fromHtml(commitString, HtmlCompat.FROM_HTML_MODE_LEGACY));
start.setTextSize(fontSize);
timelineData.setOrientation(LinearLayout.VERTICAL);
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_commit));
timelineData.addView(start);
for(int i = 0; i < Objects.requireNonNull(commitsShaArray).length(); i++) {
try {
String timelineCommits = "<font color='" + ResourcesCompat.getColor(context.getResources(), R.color.lightBlue, null) + "'>" + StringUtils.substring(String.valueOf(commitsShaArray.get(i)), 0, 10) + "</font>";
TextView dynamicCommitTv = new TextView(context);
dynamicCommitTv.setId(View.generateViewId());
dynamicCommitTv.setText(HtmlCompat.fromHtml(timelineCommits, HtmlCompat.FROM_HTML_MODE_LEGACY));
JSONArray finalCommitsArray = commitsShaArray;
int finalI = i;
dynamicCommitTv.setOnClickListener(v14 -> {
intent = IssueContext.fromIntent(((IssueDetailActivity) context).getIntent()).getRepository().getIntent(context, CommitDetailActivity.class);
try {
intent.putExtra("sha", (String) finalCommitsArray.get(finalI));
}
catch(JSONException ignored) {}
context.startActivity(intent);
});
timelineData.setOrientation(LinearLayout.VERTICAL);
timelineData.addView(dynamicCommitTv);
}
catch(JSONException ignored) {}
}
}
// assignees data view in timeline
else if(issueComment.getType().equalsIgnoreCase("assignees")) {
TextView start = new TextView(context);
if(issueComment.isRemovedAssignee()) {
if(issueComment.getUser().getLogin().equalsIgnoreCase(issueComment.getAssignee().getLogin())) {
start.setText(context.getString(R.string.timelineAssigneesRemoved, issueComment.getUser().getLogin(), informationBuilder));
}
else {
start.setText(context.getString(R.string.timelineAssigneesUnassigned, issueComment.getAssignee().getLogin(), issueComment.getUser().getLogin(), informationBuilder));
}
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
else {
if(issueComment.getUser().getLogin().equalsIgnoreCase(issueComment.getAssignee().getLogin())) {
start.setText(context.getString(R.string.timelineAssigneesSelfAssigned, issueComment.getUser().getLogin(), informationBuilder));
}
else {
start.setText(context.getString(R.string.timelineAssigneesAssigned, issueComment.getAssignee().getLogin(), issueComment.getUser().getLogin(), informationBuilder));
}
}
start.setTextSize(fontSize);
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_person));
timelineData.addView(start);
}
// milestone data view in timeline
else if(issueComment.getType().equalsIgnoreCase("milestone")) {
TextView start = new TextView(context);
if(issueComment.getMilestone() != null) {
start.setText(context.getString(R.string.timelineMilestoneAdded, issueComment.getUser().getLogin(), issueComment.getMilestone().getTitle(), informationBuilder));
}
else {
start.setText(context.getString(R.string.timelineMilestoneRemoved, issueComment.getUser().getLogin(), issueComment.getOldMilestone().getTitle(), informationBuilder));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
start.setTextSize(fontSize);
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_milestone));
timelineData.addView(start);
}
// status view in timeline
else if(issueComment.getType().equalsIgnoreCase("close") || issueComment.getType().equalsIgnoreCase("reopen") || issueComment.getType().equalsIgnoreCase("merge_pull") || issueComment.getType()
.equalsIgnoreCase("commit_ref")) {
TextView start = new TextView(context);
if(issue.getIssueType().equalsIgnoreCase("Issue")) {
if(issueComment.getType().equals("close")) {
start.setText(context.getString(R.string.timelineStatusClosedIssue, issueComment.getUser().getLogin(), informationBuilder));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
else if(issueComment.getType().equalsIgnoreCase("reopen")) {
start.setText(context.getString(R.string.timelineStatusReopenedIssue, issueComment.getUser().getLogin(), informationBuilder));
}
else if(issueComment.getType().equalsIgnoreCase("commit_ref")) {
String commitString = context.getString(R.string.timelineStatusRefIssue, issueComment.getUser().getLogin()) + "<font color='" + ResourcesCompat.getColor(context.getResources(), R.color.lightBlue, null) + "'>" + context.getResources().getString(R.string.commitText).toLowerCase() + "</font> " + informationBuilder;
start.setText(HtmlCompat.fromHtml(commitString, HtmlCompat.FROM_HTML_MODE_LEGACY));
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_bookmark));
start.setOnClickListener(v14 -> {
intent = IssueContext.fromIntent(((IssueDetailActivity) context).getIntent()).getRepository().getIntent(context, CommitDetailActivity.class);
intent.putExtra("sha", issueComment.getRefCommitSha());
context.startActivity(intent);
});
}
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_issue));
}
else if(issue.getIssueType().equalsIgnoreCase("Pull")) {
if(issueComment.getType().equalsIgnoreCase("close")) {
start.setText(context.getString(R.string.timelineStatusClosedPr, issueComment.getUser().getLogin(), informationBuilder));
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_pull_request));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
else if(issueComment.getType().equalsIgnoreCase("merge_pull")) {
start.setText(context.getString(R.string.timelineStatusMergedPr, issueComment.getUser().getLogin(), informationBuilder));
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_pull_request));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconPrMergedColor, null));
}
else if(issueComment.getType().equalsIgnoreCase("commit_ref")) {
String commitString = context.getString(R.string.timelineStatusRefPr, issueComment.getUser().getLogin()) + "<font color='" + ResourcesCompat.getColor(context.getResources(), R.color.lightBlue, null) + "'>" + context.getResources().getString(R.string.commitText).toLowerCase() + "</font> " + informationBuilder;
start.setText(HtmlCompat.fromHtml(commitString, HtmlCompat.FROM_HTML_MODE_LEGACY));
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_bookmark));
start.setOnClickListener(v14 -> {
intent = IssueContext.fromIntent(((IssueDetailActivity) context).getIntent()).getRepository().getIntent(context, CommitDetailActivity.class);
intent.putExtra("sha", issueComment.getRefCommitSha());
context.startActivity(intent);
});
}
else {
start.setText(context.getString(R.string.timelineStatusReopenedPr, issueComment.getUser().getLogin(), informationBuilder));
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_pull_request));
}
}
start.setTextSize(fontSize);
timelineData.addView(start);
}
// review data view in timeline
else if(issueComment.getType().equalsIgnoreCase("review_request") || issueComment.getType().equalsIgnoreCase("review") || issueComment.getType().equalsIgnoreCase("dismiss_review")) {
TextView start = new TextView(context);
if(issueComment.getType().equalsIgnoreCase("review")) {
timelineView.setVisibility(View.GONE);
timelineDividerView.setVisibility(View.GONE);
}
else if(issueComment.getType().equalsIgnoreCase("dismiss_review")) {
timelineView.setVisibility(View.GONE);
timelineDividerView.setVisibility(View.GONE);
}
else if(issueComment.getType().equalsIgnoreCase("review_request")) {
start.setText(context.getString(R.string.timelineReviewRequest, issueComment.getUser().getLogin(), issueComment.getAssignee().getLogin(), informationBuilder));
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_unwatch));
}
start.setTextSize(fontSize);
timelineData.addView(start);
}
// change title data view in timeline
else if(issueComment.getType().equalsIgnoreCase("change_title")) {
TextView start = new TextView(context);
start.setText(context.getString(R.string.timelineChangeTitle, issueComment.getUser().getLogin(), issueComment.getOldTitle(), issueComment.getNewTitle(), informationBuilder));
start.setTextSize(fontSize);
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_edit));
timelineData.addView(start);
}
// lock/unlock data view in timeline
else if(issueComment.getType().equalsIgnoreCase("lock") || issueComment.getType().equalsIgnoreCase("unlock")) {
TextView start = new TextView(context);
if(issueComment.getType().equalsIgnoreCase("lock")) {
start.setText(context.getString(R.string.timelineLocked, issueComment.getUser().getLogin(), issueComment.getBody(), informationBuilder));
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_lock));
}
else if(issueComment.getType().equalsIgnoreCase("unlock")) {
start.setText(context.getString(R.string.timelineUnlocked, issueComment.getUser().getLogin(), informationBuilder));
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_key));
}
start.setTextSize(fontSize);
timelineData.addView(start);
}
// dependency data view in timeline
else if(issueComment.getType().equalsIgnoreCase("add_dependency") || issueComment.getType().equalsIgnoreCase("remove_dependency")) {
TextView start = new TextView(context);
if(issueComment.getType().equalsIgnoreCase("add_dependency")) {
start.setText(context.getString(R.string.timelineDependencyAdded, issueComment.getUser().getLogin(), issueComment.getDependentIssue().getNumber(), informationBuilder));
}
else if(issueComment.getType().equalsIgnoreCase("remove_dependency")) {
start.setText(context.getString(R.string.timelineDependencyRemoved, issueComment.getUser().getLogin(), issueComment.getDependentIssue().getNumber(), informationBuilder));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
start.setTextSize(fontSize);
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_dependency));
timelineData.addView(start);
}
// project data view in timeline
else if(issueComment.getType().equalsIgnoreCase("project") || issueComment.getType().equalsIgnoreCase("project_board")) {
TextView start = new TextView(context);
if(issueComment.getProjectId() > 0) {
start.setText(context.getString(R.string.timelineProjectAdded, issueComment.getUser().getLogin(), informationBuilder));
}
else {
start.setText(context.getString(R.string.timelineProjectRemoved, issueComment.getUser().getLogin(), informationBuilder));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
start.setTextSize(fontSize);
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_kanban));
timelineData.addView(start);
}
// due date/deadline data view in timeline
else if(issueComment.getType().equalsIgnoreCase("added_deadline") || issueComment.getType().equalsIgnoreCase("modified_deadline") || issueComment.getType().equalsIgnoreCase("removed_deadline")) {
TextView start = new TextView(context);
if(issueComment.getType().equalsIgnoreCase("added_deadline")) {
start.setText(context.getString(R.string.timelineDueDateAdded, issueComment.getUser().getLogin(), issueComment.getBody(), informationBuilder));
}
else if(issueComment.getType().equalsIgnoreCase("modified_deadline")) {
start.setText(
context.getString(R.string.timelineDueDateModified, issueComment.getUser().getLogin(), issueComment.getBody().split("\\|")[0], issueComment.getBody().split("\\|")[1], informationBuilder));
}
else if(issueComment.getType().equalsIgnoreCase("removed_deadline")) {
start.setText(context.getString(R.string.timelineDueDateRemoved, issueComment.getUser().getLogin(), issueComment.getBody(), informationBuilder));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
start.setTextSize(fontSize);
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_clock));
timelineData.addView(start);
}
// branch data view in timeline
else if(issueComment.getType().equalsIgnoreCase("change_target_branch") || issueComment.getType().equalsIgnoreCase("delete_branch")) {
TextView start = new TextView(context);
if(issueComment.getType().equalsIgnoreCase("change_target_branch")) {
start.setText(context.getString(R.string.timelineBranchChanged, issueComment.getUser().getLogin(), issueComment.getOldRef(), issueComment.getNewRef(), informationBuilder));
}
else if(issueComment.getType().equalsIgnoreCase("delete_branch")) {
start.setText(context.getString(R.string.timelineBranchDeleted, issueComment.getUser().getLogin(), issueComment.getOldRef(), informationBuilder));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
start.setTextSize(fontSize);
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_branch));
timelineData.addView(start);
}
// time tracking data view in timeline
else if(issueComment.getType().equalsIgnoreCase("start_tracking") || issueComment.getType().equalsIgnoreCase("stop_tracking") || issueComment.getType()
.equalsIgnoreCase("cancel_tracking") || issueComment.getType().equalsIgnoreCase("add_time_manual") || issueComment.getType().equalsIgnoreCase("delete_time_manual")) {
TextView start = new TextView(context);
if(issueComment.getType().equalsIgnoreCase("start_tracking")) {
start.setText(context.getString(R.string.timelineTimeTrackingStart, issueComment.getUser().getLogin(), informationBuilder));
}
else if(issueComment.getType().equalsIgnoreCase("stop_tracking")) {
start.setText(context.getString(R.string.timelineTimeTrackingStop, issueComment.getUser().getLogin(), informationBuilder));
}
else if(issueComment.getType().equalsIgnoreCase("cancel_tracking")) {
start.setText(context.getString(R.string.timelineTimeTrackingCancel, issueComment.getUser().getLogin(), informationBuilder));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
else if(issueComment.getType().equalsIgnoreCase("add_time_manual")) {
start.setText(context.getString(R.string.timelineTimeTrackingAddManualTime, issueComment.getUser().getLogin(), issueComment.getBody(), informationBuilder));
}
else if(issueComment.getType().equalsIgnoreCase("delete_time_manual")) {
start.setText(context.getString(R.string.timelineTimeTrackingDeleteManualTime, issueComment.getUser().getLogin(), issueComment.getBody(), informationBuilder));
timelineIcon.setColorFilter(context.getResources().getColor(R.color.iconIssuePrClosedColor, null));
}
start.setTextSize(fontSize);
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_clock));
timelineData.addView(start);
}
// issue/pr refs data view in timeline
else if(issueComment.getType().equalsIgnoreCase("change_issue_ref") || issueComment.getType().equalsIgnoreCase("issue_ref") || issueComment.getType().equalsIgnoreCase("comment_ref") || issueComment.getType()
.equalsIgnoreCase("pull_ref")) {
RecyclerView recyclerView = new RecyclerView(context);
if(issueComment.getType().equalsIgnoreCase("change_issue_ref")) {
String text = context.getString(R.string.timelineChangeIssueRef, issueComment.getUser().getLogin(), issueComment.getNewRef(), informationBuilder);
Markdown.render(context, EmojiParser.parseToUnicode(text), recyclerView, issue.getRepository());
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_branch));
}
else if(issueComment.getType().equalsIgnoreCase("comment_ref") || issueComment.getType().equalsIgnoreCase("issue_ref") || issueComment.getType().equalsIgnoreCase("pull_ref")) {
if(issue.getIssueType().equalsIgnoreCase("Issue")) {
String text = context.getString(R.string.timelineRefIssue, issueComment.getUser().getLogin(), issueComment.getRefIssue().getNumber(), informationBuilder);
Markdown.render(context, EmojiParser.parseToUnicode(text), recyclerView, issue.getRepository());
}
else if(issue.getIssueType().equalsIgnoreCase("Pull")) {
String text = context.getString(R.string.timelineRefPr, issueComment.getUser().getLogin(), issueComment.getRefIssue().getNumber(), informationBuilder);
Markdown.render(context, EmojiParser.parseToUnicode(text), recyclerView, issue.getRepository());
}
timelineIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_bookmark));
}
timelineData.addView(recyclerView);
}
// code data view in timeline
else if(issueComment.getType().equalsIgnoreCase("code")) {
timelineView.setVisibility(View.GONE);
timelineDividerView.setVisibility(View.GONE);
}
// schedule pr view in timeline
else if(issueComment.getType().equalsIgnoreCase("pull_scheduled_merge") || issueComment.getType().equalsIgnoreCase("pull_cancel_scheduled_merge")) {
timelineView.setVisibility(View.GONE);
timelineDividerView.setVisibility(View.GONE);
}
else {
timelineView.setVisibility(View.GONE);
}
// comment data view in timeline
if(issueComment.getType().equalsIgnoreCase("comment")) {
author.setText(issueComment.getUser().getLogin());
PicassoService.getInstance(context).get().load(issueComment.getUser().getAvatarUrl()).placeholder(R.drawable.loader_animated).transform(new RoundedTransformation(imgRadius, 0))
.resize(AppUtil.getPixelsFromDensity(context, 35), AppUtil.getPixelsFromDensity(context, 35)).centerCrop().into(avatar);
Markdown.render(context, EmojiParser.parseToUnicode(issueComment.getBody()), comment, issue.getRepository());
information.setText(informationBuilder);
Bundle bundle1 = new Bundle();
bundle1.putAll(bundle);
bundle1.putInt("commentId", Math.toIntExact(issueComment.getId()));
ReactionList reactionList = new ReactionList(context, bundle1);
commentReactionBadges.addView(reactionList);
reactionList.setOnReactionAddedListener(() -> {
if(commentReactionBadges.getVisibility() != View.VISIBLE) {
commentReactionBadges.post(() -> commentReactionBadges.setVisibility(View.VISIBLE));
}
});
}
else {
commentView.setVisibility(View.GONE);
}
}
}
}

View File

@ -15,6 +15,7 @@ import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;
import androidx.annotation.NonNull;
import androidx.core.content.ContextCompat;
import androidx.core.content.res.ResourcesCompat;
import androidx.core.text.HtmlCompat;
import androidx.recyclerview.widget.RecyclerView;
@ -26,7 +27,13 @@ import org.mian.gitnex.activities.IssueDetailActivity;
import org.mian.gitnex.activities.ProfileActivity;
import org.mian.gitnex.activities.RepoDetailActivity;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ClickListener;
import org.mian.gitnex.helpers.ColorInverter;
import org.mian.gitnex.helpers.LabelWidthCalculator;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.contexts.IssueContext;
import org.ocpsoft.prettytime.PrettyTime;
import java.text.DateFormat;
@ -111,6 +118,7 @@ public class IssuesAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
private final LinearLayout frameLabels;
private final HorizontalScrollView labelsScrollViewDots;
private final LinearLayout frameLabelsDots;
private final ImageView commentIcon;
private Issue issueObject;
IssuesHolder(View itemView) {
@ -124,6 +132,7 @@ public class IssuesAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
frameLabels = itemView.findViewById(R.id.frameLabels);
labelsScrollViewDots = itemView.findViewById(R.id.labelsScrollViewDots);
frameLabelsDots = itemView.findViewById(R.id.frameLabelsDots);
commentIcon = itemView.findViewById(R.id.comment_icon);
new Handler().postDelayed(() -> {
if(!AppUtil.checkGhostUsers(issueObject.getUser().getLogin())) {
@ -222,6 +231,11 @@ public class IssuesAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
}
}
if(issue.getComments() > 15) {
commentIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_flame));
commentIcon.setColorFilter(context.getResources().getColor(R.color.releasePre, null));
}
switch(timeFormat) {
case "pretty": {
PrettyTime prettyTime = new PrettyTime(locale);

View File

@ -15,6 +15,7 @@ import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;
import androidx.annotation.NonNull;
import androidx.core.content.ContextCompat;
import androidx.core.content.res.ResourcesCompat;
import androidx.core.text.HtmlCompat;
import androidx.recyclerview.widget.RecyclerView;
@ -26,7 +27,13 @@ import org.mian.gitnex.activities.IssueDetailActivity;
import org.mian.gitnex.activities.ProfileActivity;
import org.mian.gitnex.activities.RepoDetailActivity;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ClickListener;
import org.mian.gitnex.helpers.ColorInverter;
import org.mian.gitnex.helpers.LabelWidthCalculator;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.contexts.IssueContext;
import java.util.List;
import java.util.Locale;
@ -103,6 +110,7 @@ public class PullRequestsAdapter extends RecyclerView.Adapter<RecyclerView.ViewH
private final LinearLayout frameLabels;
private final HorizontalScrollView labelsScrollViewDots;
private final LinearLayout frameLabelsDots;
private final ImageView commentIcon;
private PullRequest pullRequestObject;
PullRequestsHolder(View itemView) {
@ -116,6 +124,7 @@ public class PullRequestsAdapter extends RecyclerView.Adapter<RecyclerView.ViewH
frameLabels = itemView.findViewById(R.id.frameLabels);
labelsScrollViewDots = itemView.findViewById(R.id.labelsScrollViewDots);
frameLabelsDots = itemView.findViewById(R.id.frameLabelsDots);
commentIcon = itemView.findViewById(R.id.comment_icon);
View.OnClickListener openPr = v -> {
Intent intentPrDetail = new IssueContext(pullRequestObject, ((RepoDetailActivity) context).repository).getIntent(context, IssueDetailActivity.class);
@ -219,6 +228,11 @@ public class PullRequestsAdapter extends RecyclerView.Adapter<RecyclerView.ViewH
this.prCommentsCount.setText(String.valueOf(pullRequest.getComments()));
this.prCreatedTime.setText(TimeHelper.formatTime(pullRequest.getCreatedAt(), locale, timeFormat, context));
if(pullRequest.getComments() > 15) {
commentIcon.setImageDrawable(ContextCompat.getDrawable(context, R.drawable.ic_flame));
commentIcon.setColorFilter(context.getResources().getColor(R.color.releasePre, null));
}
if(timeFormat.equals("pretty")) {
this.prCreatedTime.setOnClickListener(new ClickListener(TimeHelper.customDateFormatForToastDateFormat(pullRequest.getCreatedAt()), context));
}

View File

@ -23,7 +23,13 @@ import org.mian.gitnex.activities.RepoDetailActivity;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.databinding.FragmentReleasesBinding;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ClickListener;
import org.mian.gitnex.helpers.Markdown;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.structs.FragmentRefreshListener;
import java.util.List;
import java.util.Locale;

View File

@ -17,7 +17,11 @@ import com.amulyakhare.textdrawable.util.ColorGenerator;
import org.mian.gitnex.R;
import org.mian.gitnex.activities.RepoDetailActivity;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ClickListener;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.contexts.RepositoryContext;
import org.ocpsoft.prettytime.PrettyTime;
import java.text.DateFormat;

View File

@ -7,7 +7,11 @@ import android.graphics.Typeface;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.*;
import android.widget.CheckBox;
import android.widget.Filter;
import android.widget.Filterable;
import android.widget.ImageView;
import android.widget.TextView;
import androidx.annotation.NonNull;
import androidx.recyclerview.widget.RecyclerView;
import com.amulyakhare.textdrawable.TextDrawable;
@ -15,7 +19,11 @@ import com.amulyakhare.textdrawable.util.ColorGenerator;
import org.mian.gitnex.R;
import org.mian.gitnex.activities.RepoDetailActivity;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ClickListener;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.contexts.RepositoryContext;
import org.ocpsoft.prettytime.PrettyTime;
import java.text.DateFormat;

View File

@ -13,7 +13,11 @@ import com.google.android.material.bottomsheet.BottomSheetDialogFragment;
import org.mian.gitnex.R;
import org.mian.gitnex.actions.IssueActions;
import org.mian.gitnex.actions.PullRequestActions;
import org.mian.gitnex.activities.*;
import org.mian.gitnex.activities.BaseActivity;
import org.mian.gitnex.activities.DiffActivity;
import org.mian.gitnex.activities.EditIssueActivity;
import org.mian.gitnex.activities.IssueDetailActivity;
import org.mian.gitnex.activities.MergePullRequestActivity;
import org.mian.gitnex.databinding.BottomSheetSingleIssueBinding;
import org.mian.gitnex.helpers.AlertDialogs;
import org.mian.gitnex.helpers.AppUtil;

View File

@ -22,7 +22,13 @@ import org.mian.gitnex.adapters.DiffFilesAdapter;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.databinding.FragmentCommitDetailsBinding;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AlertDialogs;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.FileDiffView;
import org.mian.gitnex.helpers.ParseDiff;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.contexts.IssueContext;
import org.mian.gitnex.helpers.contexts.RepositoryContext;
import java.util.ArrayList;
@ -172,7 +178,7 @@ public class CommitDetailFragment extends Fragment {
if(commitsModel.getAuthor() != null && commitsModel.getAuthor().getAvatarUrl() != null && !commitsModel.getAuthor().getAvatarUrl().isEmpty()) {
binding.commitAuthorAvatar.setVisibility(View.VISIBLE);
binding.commitAuthorAvatarFrame.setVisibility(View.VISIBLE);
int imgRadius = AppUtil.getPixelsFromDensity(requireContext(), 3);
@ -188,13 +194,13 @@ public class CommitDetailFragment extends Fragment {
}
else {
binding.commitAuthorAvatar.setImageDrawable(null);
binding.commitAuthorAvatar.setVisibility(View.GONE);
binding.commitAuthorAvatarFrame.setVisibility(View.GONE);
}
if(commitsModel.getCommitter() != null && (commitsModel.getAuthor() == null || !commitsModel.getAuthor().getLogin().equals(commitsModel.getCommitter().getLogin())) && commitsModel.getCommitter()
.getAvatarUrl() != null && !commitsModel.getCommitter().getAvatarUrl().isEmpty()) {
binding.commitCommitterAvatar.setVisibility(View.VISIBLE);
binding.commitCommitterAvatarFrame.setVisibility(View.VISIBLE);
int imgRadius = AppUtil.getPixelsFromDensity(requireContext(), 3);
@ -210,7 +216,7 @@ public class CommitDetailFragment extends Fragment {
}
else {
binding.commitCommitterAvatar.setImageDrawable(null);
binding.commitCommitterAvatar.setVisibility(View.GONE);
binding.commitCommitterAvatarFrame.setVisibility(View.GONE);
}
binding.commitSha.setText(commitsModel.getSha().substring(0, Math.min(commitsModel.getSha().length(), 10)));
@ -241,5 +247,4 @@ public class CommitDetailFragment extends Fragment {
binding.progressBar.setVisibility(View.GONE);
}
}
}

View File

@ -3,7 +3,12 @@ package org.mian.gitnex.fragments;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

View File

@ -4,7 +4,12 @@ import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

View File

@ -4,7 +4,12 @@ import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

View File

@ -4,7 +4,12 @@ import android.annotation.SuppressLint;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.activity.OnBackPressedCallback;
import androidx.annotation.NonNull;

View File

@ -4,7 +4,12 @@ import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

View File

@ -26,13 +26,13 @@ import org.mian.gitnex.viewmodels.IssuesViewModel;
public class MyIssuesFragment extends Fragment {
public String state = "open";
public boolean assignedToMe = false;
private IssuesViewModel issuesViewModel;
private FragmentIssuesBinding fragmentIssuesBinding;
private ExploreIssuesAdapter adapter;
private int page = 1;
private Menu menu;
public String state = "open";
public boolean assignedToMe = false;
@Override
public View onCreateView(@NonNull LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
@ -75,8 +75,6 @@ public class MyIssuesFragment extends Fragment {
return fragmentIssuesBinding.getRoot();
}
;
private void fetchDataAsync(String query, String state, boolean assignedToMe) {
issuesViewModel.getIssuesList(query, "issues", true, state, assignedToMe, getContext()).observe(getViewLifecycleOwner(), issuesListMain -> {

View File

@ -5,7 +5,12 @@ import android.content.res.ColorStateList;
import android.graphics.Typeface;
import android.os.Bundle;
import android.text.Html;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageView;
import android.widget.TextView;
import androidx.annotation.NonNull;

View File

@ -4,7 +4,12 @@ import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

View File

@ -4,7 +4,12 @@ import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.fragment.app.Fragment;

View File

@ -3,7 +3,12 @@ package org.mian.gitnex.fragments;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

View File

@ -4,7 +4,12 @@ import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

View File

@ -5,7 +5,12 @@ import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.util.Log;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import android.widget.RelativeLayout;
import androidx.annotation.NonNull;

View File

@ -5,7 +5,12 @@ import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.util.Log;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

View File

@ -16,10 +16,21 @@ import org.gitnex.tea4j.v2.models.Organization;
import org.gitnex.tea4j.v2.models.Repository;
import org.jetbrains.annotations.NotNull;
import org.mian.gitnex.R;
import org.mian.gitnex.activities.*;
import org.mian.gitnex.activities.OrganizationDetailActivity;
import org.mian.gitnex.activities.ProfileActivity;
import org.mian.gitnex.activities.RepoDetailActivity;
import org.mian.gitnex.activities.RepoForksActivity;
import org.mian.gitnex.activities.RepoStargazersActivity;
import org.mian.gitnex.activities.RepoWatchersActivity;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.databinding.FragmentRepoInfoBinding;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AlertDialogs;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ClickListener;
import org.mian.gitnex.helpers.Markdown;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.helpers.contexts.RepositoryContext;
import java.io.IOException;
import java.util.Locale;

View File

@ -4,7 +4,12 @@ import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

View File

@ -13,7 +13,15 @@ import androidx.annotation.Nullable;
import androidx.fragment.app.Fragment;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import org.mian.gitnex.R;
import org.mian.gitnex.activities.*;
import org.mian.gitnex.activities.BaseActivity;
import org.mian.gitnex.activities.MainActivity;
import org.mian.gitnex.activities.SettingsAppearanceActivity;
import org.mian.gitnex.activities.SettingsDraftsActivity;
import org.mian.gitnex.activities.SettingsGeneralActivity;
import org.mian.gitnex.activities.SettingsNotificationsActivity;
import org.mian.gitnex.activities.SettingsReportsActivity;
import org.mian.gitnex.activities.SettingsSecurityActivity;
import org.mian.gitnex.activities.SettingsTranslationActivity;
import org.mian.gitnex.databinding.CustomAboutDialogBinding;
import org.mian.gitnex.databinding.FragmentSettingsBinding;
import org.mian.gitnex.helpers.AppUtil;

View File

@ -4,7 +4,12 @@ import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

View File

@ -12,7 +12,14 @@ import org.mian.gitnex.R;
import org.mian.gitnex.clients.PicassoService;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.databinding.FragmentProfileDetailBinding;
import org.mian.gitnex.helpers.*;
import org.mian.gitnex.helpers.AlertDialogs;
import org.mian.gitnex.helpers.AppUtil;
import org.mian.gitnex.helpers.ClickListener;
import org.mian.gitnex.helpers.ColorInverter;
import org.mian.gitnex.helpers.RoundedTransformation;
import org.mian.gitnex.helpers.TimeHelper;
import org.mian.gitnex.helpers.TinyDB;
import org.mian.gitnex.helpers.Toasty;
import java.util.Locale;
import jp.wasabeef.picasso.transformations.BlurTransformation;
import retrofit2.Call;

View File

@ -4,7 +4,12 @@ import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

View File

@ -4,7 +4,12 @@ import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

View File

@ -4,7 +4,12 @@ import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

View File

@ -4,7 +4,12 @@ import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

View File

@ -4,7 +4,12 @@ import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.view.*;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.view.inputmethod.EditorInfo;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

View File

@ -1,7 +1,11 @@
package org.mian.gitnex.helpers;
import android.app.Activity;
import android.content.*;
import android.content.ActivityNotFoundException;
import android.content.ClipData;
import android.content.ClipboardManager;
import android.content.Context;
import android.content.Intent;
import android.content.pm.ActivityInfo;
import android.content.pm.PackageInfo;
import android.content.pm.PackageManager;
@ -13,7 +17,6 @@ import android.net.Uri;
import android.os.Build;
import android.util.Base64;
import android.util.DisplayMetrics;
import android.util.Log;
import android.util.TypedValue;
import android.view.View;
import androidx.annotation.ColorInt;
@ -35,7 +38,14 @@ import java.net.URL;
import java.nio.charset.StandardCharsets;
import java.text.DecimalFormat;
import java.text.SimpleDateFormat;
import java.util.*;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Collections;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Locale;
import java.util.Objects;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
@ -109,7 +119,6 @@ public class AppUtil {
}
return FileType.UNKNOWN;
}
public static boolean hasNetworkConnection(Context context) {
@ -193,7 +202,6 @@ public class AppUtil {
}
public static Boolean checkIntegers(String str) {
return str.matches("\\d+");
}
@ -203,7 +211,6 @@ public class AppUtil {
Configuration config = resource.getConfiguration();
config.setLocale(new Locale(locCode.toLowerCase()));
resource.updateConfiguration(config, dm);
}
public static String getTimestampFromDate(Context context, Date date) {
@ -217,7 +224,6 @@ public class AppUtil {
else {
return new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss", locale).format(date);
}
}
@ColorInt
@ -227,7 +233,6 @@ public class AppUtil {
context.getTheme().resolveAttribute(resid, typedValue, true);
return typedValue.data;
}
public static String customDateFormat(String customDate) {
@ -254,7 +259,6 @@ public class AppUtil {
}
return year + "-" + sMonth + "-" + sDay;
}
public static String customDateCombine(String customDate) {
@ -281,7 +285,6 @@ public class AppUtil {
}
return (customDate + "T" + mHour + ":" + sMin + ":" + sSec + "Z");
}
public static String encodeBase64(String str) {
@ -293,7 +296,6 @@ public class AppUtil {
}
return base64Str;
}
public static String decodeBase64(String str) {
@ -305,7 +307,6 @@ public class AppUtil {
}
return base64Str;
}
public static String getLastCharactersOfWord(String str, int count) {
@ -342,7 +343,6 @@ public class AppUtil {
lines++;
return lines;
}
public static void copyToClipboard(Context ctx, CharSequence data, String message) {
@ -522,7 +522,6 @@ public class AppUtil {
URL url = new URL(u);
HttpURLConnection http = (HttpURLConnection) url.openConnection();
return (http.getResponseCode());
}
public enum FileType {IMAGE, AUDIO, VIDEO, DOCUMENT, TEXT, EXECUTABLE, FONT, UNKNOWN}
@ -536,7 +535,5 @@ public class AppUtil {
}
void onProgressChanged(short progress);
}
}

View File

@ -10,7 +10,12 @@ import androidx.core.content.res.ResourcesCompat;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import org.commonmark.ext.gfm.tables.TableBlock;
import org.commonmark.node.*;
import org.commonmark.node.AbstractVisitor;
import org.commonmark.node.FencedCodeBlock;
import org.commonmark.node.Image;
import org.commonmark.node.Link;
import org.commonmark.node.Node;
import org.commonmark.node.Text;
import org.commonmark.parser.InlineParserFactory;
import org.commonmark.parser.Parser;
import org.commonmark.parser.PostProcessor;
@ -55,7 +60,13 @@ import io.noties.markwon.recycler.SimpleEntry;
import io.noties.markwon.recycler.table.TableEntry;
import io.noties.markwon.recycler.table.TableEntryPlugin;
import io.noties.prism4j.Prism4j;
import stormpot.*;
import stormpot.Allocator;
import stormpot.BlazePool;
import stormpot.Config;
import stormpot.Pool;
import stormpot.Poolable;
import stormpot.Slot;
import stormpot.Timeout;
/**
* @author opyale

View File

@ -6,7 +6,12 @@ import android.graphics.BitmapFactory;
import android.util.Log;
import com.squareup.picasso.Cache;
import org.mian.gitnex.R;
import java.io.*;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.ObjectInputStream;
import java.io.ObjectOutputStream;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;

View File

@ -1,6 +1,11 @@
package org.mian.gitnex.helpers;
import android.graphics.*;
import android.graphics.Bitmap;
import android.graphics.BitmapShader;
import android.graphics.Canvas;
import android.graphics.Paint;
import android.graphics.RectF;
import android.graphics.Shader;
/**
* @author M M Arif

View File

@ -5,7 +5,11 @@ import android.app.NotificationManager;
import android.content.Context;
import android.graphics.Color;
import android.os.Build;
import androidx.work.*;
import androidx.work.Constraints;
import androidx.work.ExistingPeriodicWorkPolicy;
import androidx.work.NetworkType;
import androidx.work.PeriodicWorkRequest;
import androidx.work.WorkManager;
import org.mian.gitnex.R;
import org.mian.gitnex.helpers.Constants;
import org.mian.gitnex.helpers.TinyDB;

View File

@ -5,9 +5,11 @@ import androidx.annotation.NonNull;
import androidx.lifecycle.LiveData;
import androidx.lifecycle.MutableLiveData;
import androidx.lifecycle.ViewModel;
import org.gitnex.tea4j.v2.models.Comment;
import org.gitnex.tea4j.v2.models.TimelineComment;
import org.mian.gitnex.R;
import org.mian.gitnex.adapters.IssueCommentsAdapter;
import org.mian.gitnex.clients.RetrofitClient;
import org.mian.gitnex.helpers.Constants;
import org.mian.gitnex.helpers.Toasty;
import java.util.List;
import retrofit2.Call;
@ -20,33 +22,34 @@ import retrofit2.Response;
public class IssueCommentsViewModel extends ViewModel {
private MutableLiveData<List<Comment>> issueComments;
private MutableLiveData<List<TimelineComment>> issueComments;
private int resultLimit;
public LiveData<List<Comment>> getIssueCommentList(String owner, String repo, int index, Context ctx) {
public LiveData<List<TimelineComment>> getIssueCommentList(String owner, String repo, int index, Context ctx) {
issueComments = new MutableLiveData<>();
loadIssueComments(owner, repo, index, ctx);
return issueComments;
}
public void loadIssueComments(String owner, String repo, int index, Context ctx) {
resultLimit = Constants.getCurrentResultLimit(ctx);
loadIssueComments(owner, repo, index, ctx, null);
return issueComments;
}
public void loadIssueComments(String owner, String repo, int index, Context ctx, Runnable onLoadingFinished) {
Call<List<Comment>> call = RetrofitClient.getApiInterface(ctx).issueGetComments(owner, repo, (long) index, null, null);
Call<List<TimelineComment>> call = RetrofitClient.getApiInterface(ctx).issueGetCommentsAndTimeline(owner, repo, (long) index, null, 1, resultLimit, null);
call.enqueue(new Callback<>() {
@Override
public void onResponse(@NonNull Call<List<Comment>> call, @NonNull Response<List<Comment>> response) {
public void onResponse(@NonNull Call<List<TimelineComment>> call, @NonNull Response<List<TimelineComment>> response) {
if(response.isSuccessful()) {
issueComments.postValue(response.body());
if(onLoadingFinished != null) {
onLoadingFinished.run();
if(response.body() != null) {
issueComments.postValue(response.body());
if(onLoadingFinished != null) {
onLoadingFinished.run();
}
}
}
else {
@ -55,11 +58,52 @@ public class IssueCommentsViewModel extends ViewModel {
}
@Override
public void onFailure(@NonNull Call<List<Comment>> call, @NonNull Throwable t) {
public void onFailure(@NonNull Call<List<TimelineComment>> call, @NonNull Throwable t) {
Toasty.error(ctx, ctx.getString(R.string.genericServerResponseError));
}
});
}
public void loadMoreIssueComments(String owner, String repo, int index, Context ctx, int page, IssueCommentsAdapter adapter) {
Call<List<TimelineComment>> call = RetrofitClient.getApiInterface(ctx).issueGetCommentsAndTimeline(owner, repo, (long) index, null, page, resultLimit, null);
call.enqueue(new Callback<>() {
@Override
public void onResponse(@NonNull Call<List<TimelineComment>> call, @NonNull Response<List<TimelineComment>> response) {
if(response.isSuccessful()) {
if(response.body() != null) {
List<TimelineComment> list = issueComments.getValue();
assert list != null;
assert response.body() != null;
if(response.body().size() != 0) {
list.addAll(response.body());
adapter.updateList(list);
}
else {
adapter.setMoreDataAvailable(false);
}
}
else {
adapter.setMoreDataAvailable(false);
}
}
else {
Toasty.error(ctx, ctx.getString(R.string.genericError));
}
}
@Override
public void onFailure(@NonNull Call<List<TimelineComment>> call, @NonNull Throwable t) {
Toasty.error(ctx, ctx.getString(R.string.genericServerResponseError));
}
});
}
}

View File

@ -0,0 +1,13 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M9,4h6a2,2 0,0 1,2 2v14l-5,-3l-5,3v-14a2,2 0,0 1,2 -2"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -3,32 +3,46 @@
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#00000000"
android:pathData="M6,3L6,15"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M18,6m-3,0a3,3 0,1 1,6 0a3,3 0,1 1,-6 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M6,18m-3,0a3,3 0,1 1,6 0a3,3 0,1 1,-6 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M18,9a9,9 0,0 1,-9 9"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M7,18m-2,0a2,2 0,1 1,4 0a2,2 0,1 1,-4 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M7,6m-2,0a2,2 0,1 1,4 0a2,2 0,1 1,-4 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M17,6m-2,0a2,2 0,1 1,4 0a2,2 0,1 1,-4 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M7,8L7,16"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M9,18h6a2,2 0,0 0,2 -2v-5"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M14,14l3,-3l3,3"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
</vector>

View File

@ -1,5 +1,27 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:width="24dp"
android:height="24dp" android:viewportWidth="16" android:viewportHeight="16">
<path android:fillColor="?attr/iconsColor" android:fillType="evenOdd"
android:pathData="M6,3h1v1L6,4L6,3zM4,3h1v1L4,4L4,3zM2,3h1v1L2,4L2,3zM14,13L2,13L2,5h12v8zM14,4L8,4L8,3h6v1zM15,3c0,-0.55 -0.45,-1 -1,-1L2,2c-0.55,0 -1,0.45 -1,1v10c0,0.55 0.45,1 1,1h12c0.55,0 1,-0.45 1,-1L15,3z"/>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M5,4L19,4A1,1 0,0 1,20 5L20,19A1,1 0,0 1,19 20L5,20A1,1 0,0 1,4 19L4,5A1,1 0,0 1,5 4z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M4,8L20,8"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M8,4L8,8"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -0,0 +1,20 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#00000000"
android:pathData="M12,12m-9,0a9,9 0,1 1,18 0a9,9 0,1 1,-18 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M12,7l0,5l3,3"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
</vector>

View File

@ -0,0 +1,41 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#00000000"
android:pathData="m16,16 l2,2 4,-4"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M21,10V8a2,2 0,0 0,-1 -1.73l-7,-4a2,2 0,0 0,-2 0l-7,4A2,2 0,0 0,3 8v8a2,2 0,0 0,1 1.73l7,4a2,2 0,0 0,2 0l2,-1.14"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M16.5,9.4 L7.55,4.24"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M3.29,7l8.71,5l8.71,-5"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M12,22L12,12"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
</vector>

View File

@ -3,8 +3,11 @@
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="?attr/iconsColor"
android:fillType="evenOdd"
android:pathData="M3.75,4.5a0.25,0.25 0,0 0,-0.25 0.25v14.5c0,0.138 0.112,0.25 0.25,0.25h16.5a0.25,0.25 0,0 0,0.25 -0.25V7.687a0.25,0.25 0,0 0,-0.25 -0.25h-8.471a1.75,1.75 0,0 1,-1.447 -0.765L8.928,4.61a0.25,0.25 0,0 0,-0.208 -0.11H3.75zM2,4.75C2,3.784 2.784,3 3.75,3h4.971c0.58,0 1.12,0.286 1.447,0.765l1.404,2.063a0.25,0.25 0,0 0,0.207 0.11h8.471c0.966,0 1.75,0.783 1.75,1.75V19.25A1.75,1.75 0,0 1,20.25 21H3.75A1.75,1.75 0,0 1,2 19.25V4.75z"/>
<path
android:pathData="M5,4h4l3,3h7a2,2 0,0 1,2 2v8a2,2 0,0 1,-2 2h-14a2,2 0,0 1,-2 -2v-11a2,2 0,0 1,2 -2"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -4,7 +4,17 @@
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="?attr/iconsColor"
android:fillType="evenOdd"
android:pathData="M5,2.5a0.5,0.5 0,0 0,-0.5 0.5v18a0.5,0.5 0,0 0,0.5 0.5h14a0.5,0.5 0,0 0,0.5 -0.5L19.5,8.5h-4a2,2 0,0 1,-2 -2v-4L5,2.5zM15,2.5v4a0.5,0.5 0,0 0,0.5 0.5h4a0.5,0.5 0,0 0,-0.146 -0.336l-4.018,-4.018A0.5,0.5 0,0 0,15 2.5zM3,3a2,2 0,0 1,2 -2h9.982a2,2 0,0 1,1.414 0.586l4.018,4.018A2,2 0,0 1,21 7.018L21,21a2,2 0,0 1,-2 2L5,23a2,2 0,0 1,-2 -2L3,3z"/>
android:pathData="M14,3v4a1,1 0,0 0,1 1h4"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M17,21h-10a2,2 0,0 1,-2 -2v-14a2,2 0,0 1,2 -2h7l5,5v11a2,2 0,0 1,-2 2z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -0,0 +1,13 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M8.5,14.5A2.5,2.5 0,0 0,11 12c0,-1.38 -0.5,-2 -1,-3 -1.072,-2.143 -0.224,-4.054 2,-6 0.5,2.5 2,4.9 4,6.5 2,1.6 3,3.5 3,5.5a7,7 0,1 1,-14 0c0,-1.153 0.433,-2.294 1,-3a2.5,2.5 0,0 0,2.5 2.5z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -3,16 +3,39 @@
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="?attr/iconsColor"
android:fillType="evenOdd"
android:pathData="M12,21a1.75,1.75 0,1 1,0 -3.5,1.75 1.75,0 0,1 0,3.5zM8.75,19.25a3.25,3.25 0,1 0,6.5 0,3.25 3.25,0 0,0 -6.5,0zM5.75,6.5a1.75,1.75 0,1 1,0 -3.5,1.75 1.75,0 0,1 0,3.5zM2.5,4.75a3.25,3.25 0,1 0,6.5 0,3.25 3.25,0 0,0 -6.5,0zM18.25,6.5a1.75,1.75 0,1 1,0 -3.5,1.75 1.75,0 0,1 0,3.5zM15,4.75a3.25,3.25 0,1 0,6.5 0,3.25 3.25,0 0,0 -6.5,0z"/>
<path
android:fillColor="?attr/iconsColor"
android:fillType="evenOdd"
android:pathData="M6.5,7.75v1A2.25,2.25 0,0 0,8.75 11h6.5a2.25,2.25 0,0 0,2.25 -2.25v-1H19v1a3.75,3.75 0,0 1,-3.75 3.75h-6.5A3.75,3.75 0,0 1,5 8.75v-1h1.5z"/>
<path
android:fillColor="?attr/iconsColor"
android:fillType="evenOdd"
android:pathData="M11.25,16.25v-5h1.5v5h-1.5z"/>
<path
android:fillColor="#00000000"
android:pathData="M12,18m-2,0a2,2 0,1 1,4 0a2,2 0,1 1,-4 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M7,6m-2,0a2,2 0,1 1,4 0a2,2 0,1 1,-4 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M17,6m-2,0a2,2 0,1 1,4 0a2,2 0,1 1,-4 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M7,8v2a2,2 0,0 0,2 2h6a2,2 0,0 0,2 -2v-2"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M12,12L12,16"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
</vector>

View File

@ -0,0 +1,20 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#00000000"
android:pathData="M12,8l0,4l2,2"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M3.05,11a9,9 0,1 1,0.5 4m-0.5,5v-5h5"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
</vector>

View File

@ -0,0 +1,34 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#00000000"
android:pathData="M4,4L10,4"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M14,4L20,4"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M6,8L8,8A2,2 0,0 1,10 10L10,18A2,2 0,0 1,8 20L6,20A2,2 0,0 1,4 18L4,10A2,2 0,0 1,6 8z"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
<path
android:fillColor="#00000000"
android:pathData="M16,8L18,8A2,2 0,0 1,20 10L20,12A2,2 0,0 1,18 14L16,14A2,2 0,0 1,14 12L14,10A2,2 0,0 1,16 8z"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round" />
</vector>

View File

@ -0,0 +1,34 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M8,15m-4,0a4,4 0,1 1,8 0a4,4 0,1 1,-8 0"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M10.85,12.15L19,4"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M18,5L20,7"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M15,8L17,10"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -3,8 +3,25 @@
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="?attr/iconsColor"
android:fillType="evenOdd"
android:pathData="M11.75,1a0.75,0.75 0,0 1,0.75 0.75L12.5,4h6.532c0.42,0 0.826,0.15 1.143,0.425l3.187,2.75a1.75,1.75 0,0 1,0 2.65l-3.187,2.75a1.75,1.75 0,0 1,-1.143 0.425L12.5,13v9.25a0.75,0.75 0,0 1,-1.5 0L11,13L3.75,13A1.75,1.75 0,0 1,2 11.25v-5.5C2,4.783 2.784,4 3.75,4L11,4L11,1.75a0.75,0.75 0,0 1,0.75 -0.75zM11.75,5.5h7.282a0.25,0.25 0,0 1,0.163 0.06l3.188,2.75a0.25,0.25 0,0 1,0 0.38l-3.188,2.75a0.25,0.25 0,0 1,-0.163 0.06L3.75,11.5a0.25,0.25 0,0 1,-0.25 -0.25v-5.5a0.25,0.25 0,0 1,0.25 -0.25h8z"/>
<path
android:pathData="M18,6H5a2,2 0,0 0,-2 2v3a2,2 0,0 0,2 2h13l4,-3.5L18,6Z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M12,13v9"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M12,2v4"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -3,11 +3,53 @@
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="?attr/iconsColor"
android:pathData="M7.25,12a0.75,0.75 0,0 0,0 1.5h0.5a0.75,0.75 0,0 0,0 -1.5h-0.5zM6.5,9.25a0.75,0.75 0,0 1,0.75 -0.75h0.5a0.75,0.75 0,0 1,0 1.5h-0.5a0.75,0.75 0,0 1,-0.75 -0.75zM7.25,5a0.75,0.75 0,0 0,0 1.5h0.5a0.75,0.75 0,0 0,0 -1.5h-0.5zM10,12.75a0.75,0.75 0,0 1,0.75 -0.75h0.5a0.75,0.75 0,0 1,0 1.5h-0.5a0.75,0.75 0,0 1,-0.75 -0.75zM10.75,8.5a0.75,0.75 0,0 0,0 1.5h0.5a0.75,0.75 0,0 0,0 -1.5h-0.5zM10,5.75a0.75,0.75 0,0 1,0.75 -0.75h0.5a0.75,0.75 0,0 1,0 1.5h-0.5a0.75,0.75 0,0 1,-0.75 -0.75zM14.25,12a0.75,0.75 0,0 0,0 1.5h0.5a0.75,0.75 0,0 0,0 -1.5h-0.5zM13.5,9.25a0.75,0.75 0,0 1,0.75 -0.75h0.5a0.75,0.75 0,0 1,0 1.5h-0.5a0.75,0.75 0,0 1,-0.75 -0.75zM14.25,5a0.75,0.75 0,0 0,0 1.5h0.5a0.75,0.75 0,0 0,0 -1.5h-0.5z"/>
<path
android:fillColor="?attr/iconsColor"
android:fillType="evenOdd"
android:pathData="M3,20a2,2 0,0 0,2 2h3.75a0.75,0.75 0,0 0,0.75 -0.75L9.5,19h3v2.25c0,0.414 0.336,0.75 0.75,0.75L17,22c0.092,0 0.183,-0.006 0.272,-0.018a0.758,0.758 0,0 0,0.166 0.018L21.5,22a2,2 0,0 0,2 -2v-7.625a2,2 0,0 0,-0.8 -1.6l-1,-0.75a0.75,0.75 0,1 0,-0.9 1.2l1,0.75a0.5,0.5 0,0 1,0.2 0.4L22,20a0.5,0.5 0,0 1,-0.5 0.5h-2.563c0.041,-0.16 0.063,-0.327 0.063,-0.5L19,3a2,2 0,0 0,-2 -2L5,1a2,2 0,0 0,-2 2v17zM5,20.5a0.5,0.5 0,0 1,-0.5 -0.5L4.5,3a0.5,0.5 0,0 1,0.5 -0.5h12a0.5,0.5 0,0 1,0.5 0.5v17a0.5,0.5 0,0 1,-0.5 0.5h-3v-2.25a0.75,0.75 0,0 0,-0.75 -0.75h-4.5a0.75,0.75 0,0 0,-0.75 0.75v2.25L5,20.5z"/>
<path
android:pathData="M6,22V4c0,-0.27 0,-0.55 0.07,-0.82a1.477,1.477 0,0 1,1.1 -1.11C7.46,2 8.73,2 9,2h7c0.27,0 0.55,0 0.82,0.07a1.477,1.477 0,0 1,1.11 1.1c0.07,0.28 0.07,0.56 0.07,0.83v18H6Z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M2,14v6c0,1.1 0.9,2 2,2h2V12H4c-0.27,0 -0.55,0 -0.82,0.07 -0.27,0.07 -0.52,0.2 -0.72,0.4 -0.19,0.19 -0.32,0.44 -0.39,0.71A3.4,3.4 0,0 0,2 14Z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M20.82,9.07A3.4,3.4 0,0 0,20 9h-2v13h2a2,2 0,0 0,2 -2v-9c0,-0.28 0,-0.55 -0.07,-0.82 -0.07,-0.27 -0.2,-0.52 -0.4,-0.72 -0.19,-0.19 -0.44,-0.32 -0.71,-0.39Z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M10,6h4"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M10,10h4"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M10,14h4"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M10,18h4"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -3,32 +3,46 @@
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#00000000"
android:pathData="M18,18m-3,0a3,3 0,1 1,6 0a3,3 0,1 1,-6 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M6,6m-3,0a3,3 0,1 1,6 0a3,3 0,1 1,-6 0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M13,6h3a2,2 0,0 1,2 2v7"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M6,9L6,21"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:pathData="M6,18m-2,0a2,2 0,1 1,4 0a2,2 0,1 1,-4 0"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M6,6m-2,0a2,2 0,1 1,4 0a2,2 0,1 1,-4 0"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M18,18m-2,0a2,2 0,1 1,4 0a2,2 0,1 1,-4 0"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M6,8L6,16"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M11,6h5a2,2 0,0 1,2 2v8"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M14,9l-3,-3l3,-3"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -4,10 +4,10 @@
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M4,4v5h0.582m15.356,2A8.001,8.001 0,0 0,4.582 9m0,0H9m11,11v-5h-0.581m0,0a8.003,8.003 0,0 1,-15.357 -2m15.357,2H15"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:pathData="M4,4v5h0.582m15.356,2A8.001,8.001 0,0 0,4.582 9m0,0H9m11,11v-5h-0.581m0,0a8.003,8.003 0,0 1,-15.357 -2m15.357,2H15"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
android:strokeLineCap="round"
android:strokeLineJoin="round" />
</vector>

View File

@ -3,11 +3,18 @@
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="?attr/iconsColor"
android:fillType="evenOdd"
android:pathData="M3,2.75A2.75,2.75 0,0 1,5.75 0h14.5a0.75,0.75 0,0 1,0.75 0.75v20.5a0.75,0.75 0,0 1,-0.75 0.75h-6a0.75,0.75 0,0 1,0 -1.5h5.25v-4H6A1.5,1.5 0,0 0,4.5 18v0.75c0,0.716 0.43,1.334 1.05,1.605a0.75,0.75 0,0 1,-0.6 1.374A3.25,3.25 0,0 1,3 18.75v-16zM19.5,1.5V15H6c-0.546,0 -1.059,0.146 -1.5,0.401V2.75c0,-0.69 0.56,-1.25 1.25,-1.25H19.5z"/>
<path
android:fillColor="?attr/iconsColor"
android:pathData="M7,18.25a0.25,0.25 0,0 1,0.25 -0.25h5a0.25,0.25 0,0 1,0.25 0.25v5.01a0.25,0.25 0,0 1,-0.397 0.201l-2.206,-1.604a0.25,0.25 0,0 0,-0.294 0L7.397,23.46a0.25,0.25 0,0 1,-0.397 -0.2v-5.01z"/>
<path
android:pathData="M4,19.5A2.5,2.5 0,0 1,6.5 17H20"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M6.5,2H20v20H6.5A2.5,2.5 0,0 1,4 19.5v-15A2.5,2.5 0,0 1,6.5 2z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -0,0 +1,20 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M8.5,8.5m-1,0a1,1 0,1 1,2 0a1,1 0,1 1,-2 0"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
<path
android:pathData="M4,7v3.859c0,0.537 0.213,1.052 0.593,1.432l8.116,8.116a2.025,2.025 0,0 0,2.864 0l4.834,-4.834a2.025,2.025 0,0 0,0 -2.864l-8.117,-8.116a2.025,2.025 0,0 0,-1.431 -0.593h-3.859a3,3 0,0 0,-3 3z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"/>
</vector>

View File

@ -1,27 +0,0 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#00000000"
android:pathData="M23,4l0,6l-6,0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M1,20l0,-6l6,0"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
<path
android:fillColor="#00000000"
android:pathData="M3.51,9a9,9 0,0 1,14.85 -3.36L23,10M1,14l4.64,4.36A9,9 0,0 0,20.49 15"
android:strokeWidth="2"
android:strokeColor="?attr/iconsColor"
android:strokeLineCap="round"
android:strokeLineJoin="round"/>
</vector>

View File

@ -1,19 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:background="?attr/primaryBackgroundColor">
android:background="?attr/primaryBackgroundColor"
android:orientation="vertical">
<com.google.android.material.appbar.AppBarLayout
android:id="@+id/appbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:elevation="@dimen/dimen0dp"
android:theme="@style/Widget.AppCompat.SearchView">
android:theme="@style/Widget.AppCompat.SearchView"
app:elevation="@dimen/dimen0dp">
<com.google.android.material.appbar.MaterialToolbar
android:id="@+id/toolbar"
@ -25,20 +24,20 @@
android:id="@+id/issuePrState"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/ic_issue"
android:contentDescription="@string/generalImgContentText"
android:paddingStart="@dimen/dimen0dp"
android:paddingEnd="@dimen/dimen8dp"
android:visibility="gone"
android:contentDescription="@string/generalImgContentText"/>
android:src="@drawable/ic_issue"
android:visibility="gone" />
<TextView
android:id="@+id/toolbar_title"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center_vertical"
android:gravity="center_vertical"
android:textSize="@dimen/dimen20sp"
android:textColor="?attr/primaryTextColor"
android:id="@+id/toolbar_title"/>
android:textSize="@dimen/dimen20sp" />
</com.google.android.material.appbar.MaterialToolbar>
@ -46,31 +45,31 @@
<com.google.android.material.progressindicator.LinearProgressIndicator
android:id="@+id/progressBar"
style="@style/Widget.Material3.LinearProgressIndicator"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dimen56dp"
android:indeterminate="true"
style="@style/Widget.Material3.LinearProgressIndicator"
app:indicatorColor="?attr/progressIndicatorColor"/>
app:indicatorColor="?attr/progressIndicatorColor" />
<com.google.android.material.floatingactionbutton.ExtendedFloatingActionButton
android:id="@+id/addNewComment"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="@dimen/dimen16dp"
android:text="@string/commentButtonText"
android:contentDescription="@string/commentButtonText"
android:textColor="@color/colorWhite"
android:backgroundTint="?attr/fabColor"
android:layout_gravity="bottom|end"
app:iconTint="@color/colorWhite"
app:icon="@drawable/ic_reply"/>
android:layout_margin="@dimen/dimen16dp"
android:backgroundTint="?attr/fabColor"
android:contentDescription="@string/commentButtonText"
android:text="@string/commentButtonText"
android:textColor="@color/colorWhite"
app:icon="@drawable/ic_reply"
app:iconTint="@color/colorWhite" />
<RelativeLayout
android:id="@+id/relativeMainLayoutFrame"
android:layout_width="match_parent"
android:layout_marginTop="@dimen/dimen56dp"
android:layout_height="match_parent">
android:layout_height="match_parent"
android:layout_marginTop="@dimen/dimen64dp">
<androidx.swiperefreshlayout.widget.SwipeRefreshLayout
android:id="@+id/pullToRefresh"
@ -78,222 +77,252 @@
android:layout_height="wrap_content">
<androidx.core.widget.NestedScrollView
android:id="@+id/scrollViewComments"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/scrollViewComments"
android:fillViewport="true">
<RelativeLayout
android:id="@+id/relativeLayoutFrame"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="@dimen/dimen8dp">
android:paddingStart="@dimen/dimen8dp"
android:paddingTop="@dimen/dimen2dp"
android:paddingEnd="@dimen/dimen8dp"
android:paddingBottom="@dimen/dimen8dp">
<com.google.android.material.card.MaterialCardView
android:id="@+id/mainThreadCard"
android:id="@+id/titleCard"
style="?attr/materialCardViewFilledStyle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
style="?attr/materialCardViewFilledStyle"
android:layout_marginBottom="@dimen/dimen4dp"
android:layout_marginBottom="@dimen/dimen12dp"
app:cardElevation="@dimen/dimen0dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:foreground="?android:attr/selectableItemBackground"
android:background="?attr/materialCardBackgroundColor"
android:orientation="vertical">
android:foreground="?android:attr/selectableItemBackground"
android:orientation="vertical"
android:padding="@dimen/dimen12dp">
<RelativeLayout
android:id="@+id/mainIssueLayout"
<TextView
android:id="@+id/issueTitle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:padding="@dimen/dimen16dp">
android:gravity="start"
android:textColor="?attr/primaryTextColor"
android:textIsSelectable="true"
android:textSize="@dimen/dimen16sp" />
</LinearLayout>
</com.google.android.material.card.MaterialCardView>
<com.google.android.material.card.MaterialCardView
android:id="@+id/mainThreadCard"
style="?attr/materialCardViewFilledStyle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/titleCard"
android:layout_marginBottom="@dimen/dimen0dp"
app:cardElevation="@dimen/dimen0dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/materialCardBackgroundColor"
android:foreground="?android:attr/selectableItemBackground"
android:orientation="vertical"
android:padding="@dimen/dimen12dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center_vertical"
android:orientation="horizontal">
<com.google.android.material.card.MaterialCardView
android:id="@+id/assigneeAvatarFrame"
style="?attr/materialCardViewFilledStyle"
android:layout_width="@dimen/dimen24dp"
android:layout_height="@dimen/dimen24dp"
style="?attr/materialCardViewFilledStyle"
app:cardElevation="@dimen/dimen0dp"
android:layout_marginEnd="@dimen/dimen12dp"
app:cardCornerRadius="@dimen/dimen12dp">
app:cardCornerRadius="@dimen/dimen12dp"
app:cardElevation="@dimen/dimen0dp">
<ImageView
android:id="@+id/assigneeAvatar"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:contentDescription="@string/generalImgContentText"/>
android:layout_weight="0"
android:contentDescription="@string/generalImgContentText"
tools:srcCompat="@tools:sample/avatars"
tools:ignore="TooDeepLayout" />
</com.google.android.material.card.MaterialCardView>
<TextView
android:id="@+id/issueTitle"
android:layout_toEndOf="@+id/assigneeAvatarFrame"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="start"
android:textColor="?attr/primaryTextColor"
android:textIsSelectable="true"
android:textSize="@dimen/dimen16sp"/>
<LinearLayout
android:id="@+id/msdueFrame"
android:layout_toEndOf="@+id/assigneeAvatarFrame"
android:layout_below="@+id/issueTitle"
android:layout_width="match_parent"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dimen10dp"
android:layout_marginLeft="@dimen/dimen16dp"
android:layout_marginRight="@dimen/dimen16dp"
android:layout_weight="1"
android:orientation="vertical">
<LinearLayout
android:id="@+id/dueDateFrame"
android:layout_width="match_parent"
<TextView
android:id="@+id/author"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="end|center_vertical"
android:orientation="horizontal"
android:visibility="gone"
tools:ignore="UseCompoundDrawables">
<ImageView
android:layout_width="@dimen/dimen20dp"
android:layout_height="wrap_content"
app:srcCompat="@drawable/ic_calendar"
android:contentDescription="@string/generalImgContentText"/>
<TextView
android:id="@+id/issueDueDate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/dimen8dp"
android:singleLine="true"
android:textColor="?attr/primaryTextColor"
android:textSize="@dimen/dimen14sp"/>
</LinearLayout>
android:ellipsize="middle"
android:singleLine="true"
android:textColor="?attr/primaryTextColor"
android:textSize="14sp"
android:textStyle="bold" />
<LinearLayout
android:id="@+id/milestoneFrame"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="end|center_vertical"
android:orientation="horizontal"
android:visibility="gone"
tools:ignore="UseCompoundDrawables">
<ImageView
android:layout_width="@dimen/dimen20dp"
android:layout_height="wrap_content"
app:srcCompat="@drawable/ic_milestone"
android:contentDescription="@string/generalImgContentText"/>
android:orientation="horizontal">
<TextView
android:id="@+id/issueMilestone"
android:id="@+id/issueCreatedTime"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/dimen8dp"
android:singleLine="true"
android:textColor="?attr/primaryTextColor"
android:textSize="@dimen/dimen14sp"/>
android:gravity="start"
android:textColor="?attr/hintColor"
android:textSize="12sp"
android:visibility="gone" />
<TextView
android:id="@+id/issueModified"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="start"
android:text="@string/modifiedText"
android:textColor="?attr/hintColor"
android:textSize="12sp"
android:visibility="gone" />
</LinearLayout>
</LinearLayout>
<HorizontalScrollView
android:layout_below="@+id/msdueFrame"
android:layout_width="match_parent"
</LinearLayout>
<LinearLayout
android:id="@+id/dueDateFrame"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="end|center_vertical"
android:orientation="horizontal"
android:visibility="gone"
tools:ignore="UseCompoundDrawables">
<ImageView
android:layout_width="@dimen/dimen20dp"
android:layout_height="wrap_content"
android:id="@+id/assigneesScrollView"
android:layout_alignParentEnd="false"
android:foregroundGravity="right"
android:scrollbarThumbHorizontal="@android:color/transparent"
android:fillViewport="true">
android:contentDescription="@string/generalImgContentText"
app:srcCompat="@drawable/ic_calendar" />
<LinearLayout
android:id="@+id/frameAssignees"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_gravity="end"
android:gravity="end"
android:layout_marginTop="@dimen/dimen10dp">
</LinearLayout>
</HorizontalScrollView>
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/issueDescription"
android:layout_below="@+id/assigneesScrollView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="start"
android:textColor="?attr/primaryTextColor"
android:autoLink="web"
android:textColorLink="@color/lightBlue"
android:textIsSelectable="true"
android:textSize="@dimen/dimen14sp"/>
<HorizontalScrollView
android:layout_below="@+id/issueDescription"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:id="@+id/labelsScrollView"
android:layout_alignParentEnd="false"
android:foregroundGravity="right"
android:scrollbarThumbHorizontal="@android:color/transparent"
android:fillViewport="true">
<LinearLayout
android:id="@+id/frameLabels"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginTop="@dimen/dimen10dp">
</LinearLayout>
</HorizontalScrollView>
<RelativeLayout
<TextView
android:id="@+id/issueDueDate"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/issueTimeFrame"
android:layout_below="@+id/labelsScrollView"
android:orientation="horizontal"
android:layout_marginTop="@dimen/dimen10dp">
android:layout_marginStart="@dimen/dimen8dp"
android:singleLine="true"
android:textColor="?attr/primaryTextColor"
android:textSize="@dimen/dimen14sp" />
<TextView
android:id="@+id/issueCreatedTime"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="start"
android:visibility="gone"
android:textColor="?attr/hintColor"
android:textSize="@dimen/dimen12sp"/>
</LinearLayout>
<TextView
android:id="@+id/issueModified"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textColor="?attr/hintColor"
android:layout_toEndOf="@+id/issueCreatedTime"
android:textSize="@dimen/dimen12sp"
android:visibility="gone"
android:text="@string/modifiedText"/>
<LinearLayout
android:id="@+id/milestoneFrame"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="end|center_vertical"
android:orientation="horizontal"
android:visibility="gone"
tools:ignore="UseCompoundDrawables">
</RelativeLayout>
<ImageView
android:layout_width="@dimen/dimen20dp"
android:layout_height="wrap_content"
android:contentDescription="@string/generalImgContentText"
app:srcCompat="@drawable/ic_milestone" />
<TextView
android:id="@+id/issueMilestone"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/dimen8dp"
android:singleLine="true"
android:textColor="?attr/primaryTextColor"
android:textSize="@dimen/dimen14sp" />
</LinearLayout>
<HorizontalScrollView
android:id="@+id/assigneesScrollView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:fillViewport="true"
android:foregroundGravity="right"
android:visibility="gone"
android:scrollbarThumbHorizontal="@android:color/transparent">
<LinearLayout
android:id="@+id/commentReactionBadges"
android:layout_width="match_parent"
android:id="@+id/frameAssignees"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/issueTimeFrame"
android:visibility="gone"
android:layout_gravity="end"
android:layout_marginTop="@dimen/dimen10dp"
android:orientation="horizontal"/>
android:gravity="end"
android:orientation="horizontal">
</RelativeLayout>
</LinearLayout>
</HorizontalScrollView>
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/issueDescription"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="@dimen/dimen8dp"
android:autoLink="web"
android:gravity="start"
android:visibility="gone"
android:textColor="?attr/primaryTextColor"
android:textColorLink="@color/lightBlue"
android:textIsSelectable="true"
android:textSize="@dimen/dimen14sp" />
<HorizontalScrollView
android:id="@+id/labelsScrollView"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:fillViewport="true"
android:foregroundGravity="right"
android:visibility="gone"
android:scrollbarThumbHorizontal="@android:color/transparent">
<LinearLayout
android:id="@+id/frameLabels"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dimen10dp"
android:orientation="horizontal">
</LinearLayout>
</HorizontalScrollView>
<LinearLayout
android:id="@+id/commentReactionBadges"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dimen10dp"
android:orientation="horizontal"
android:visibility="gone" />
</LinearLayout>
@ -302,15 +331,15 @@
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?attr/primaryBackgroundColor"
android:layout_below="@+id/mainThreadCard">
android:layout_below="@+id/mainThreadCard"
android:background="?attr/primaryBackgroundColor">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dimen/dimen72dp"
android:clipToPadding="false"/>
android:layout_height="wrap_content"
android:clipToPadding="false"
android:paddingBottom="@dimen/dimen72dp" />
</FrameLayout>

View File

@ -82,7 +82,7 @@
android:text="@string/label"
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_label"
app:drawableTopCompat="@drawable/ic_tag"
app:layout_alignSelf="flex_start"/>
</com.google.android.flexbox.FlexboxLayout>

View File

@ -69,7 +69,7 @@
android:text="@string/tags"
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_label"
app:drawableTopCompat="@drawable/ic_tag"
app:layout_alignSelf="flex_start"/>
</com.google.android.flexbox.FlexboxLayout>

View File

@ -82,7 +82,7 @@
android:text="@string/label"
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_label"
app:drawableTopCompat="@drawable/ic_tag"
app:layout_alignSelf="flex_start"/>
<TextView

View File

@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="wrap_content"
@ -23,7 +22,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="5dp"
android:orientation="horizontal"/>
android:orientation="horizontal" />
<View
android:id="@+id/reactionDivider"
@ -31,7 +30,7 @@
android:layout_height="4dp"
android:layout_marginTop="12dp"
android:layout_marginBottom="16dp"
android:background="?attr/dividerColor"/>
android:background="?attr/dividerColor" />
<LinearLayout
android:id="@+id/bottomSheetHeaderFrame"
@ -47,7 +46,7 @@
android:gravity="center"
android:text="@string/issue"
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"/>
android:textSize="16sp" />
</LinearLayout>
@ -73,7 +72,7 @@
android:textSize="16sp"
android:visibility="gone"
app:drawableTopCompat="@drawable/ic_file"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/mergePullRequest"
@ -87,7 +86,7 @@
android:textSize="16sp"
android:visibility="gone"
app:drawableTopCompat="@drawable/ic_pull_request"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/updatePullRequest"
@ -100,8 +99,8 @@
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
android:visibility="gone"
app:drawableTopCompat="@drawable/ic_update"
app:layout_alignSelf="flex_start"/>
app:drawableTopCompat="@drawable/ic_refresh"
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/deletePrHeadBranch"
@ -114,7 +113,7 @@
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_branch"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/editIssue"
@ -127,7 +126,7 @@
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_edit"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/addRemoveAssignees"
@ -140,7 +139,7 @@
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_person_add"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/editLabels"
@ -152,8 +151,8 @@
android:text="@string/newIssueLabelsTitle"
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_label"
app:layout_alignSelf="flex_start"/>
app:drawableTopCompat="@drawable/ic_tag"
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/subscribeIssue"
@ -166,7 +165,7 @@
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_unwatch"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/unsubscribeIssue"
@ -180,7 +179,7 @@
android:textSize="16sp"
android:visibility="gone"
app:drawableTopCompat="@drawable/ic_watchers"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/closeIssue"
@ -193,7 +192,7 @@
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_issue_closed"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
</com.google.android.flexbox.FlexboxLayout>
@ -202,7 +201,7 @@
android:layout_width="match_parent"
android:layout_height="4dp"
android:layout_marginBottom="16dp"
android:background="?attr/dividerColor"/>
android:background="?attr/dividerColor" />
<com.google.android.flexbox.FlexboxLayout
android:id="@+id/issuePrShareSection"
@ -225,7 +224,7 @@
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_copy"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/shareIssue"
@ -238,7 +237,7 @@
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_share"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
<TextView
android:id="@+id/open"
@ -251,7 +250,7 @@
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
app:drawableTopCompat="@drawable/ic_browser"
app:layout_alignSelf="flex_start"/>
app:layout_alignSelf="flex_start" />
</com.google.android.flexbox.FlexboxLayout>

View File

@ -117,21 +117,42 @@
android:orientation="horizontal"
tools:ignore="UseCompoundDrawables">
<ImageView
android:id="@+id/commitAuthorAvatar"
<com.google.android.material.card.MaterialCardView
android:id="@+id/commitAuthorAvatarFrame"
android:layout_width="@dimen/dimen24dp"
android:layout_height="@dimen/dimen24dp"
android:layout_marginEnd="5dp"
android:contentDescription="@string/generalImgContentText"
tools:srcCompat="@tools:sample/avatars"/>
style="?attr/materialCardViewFilledStyle"
app:cardElevation="@dimen/dimen0dp"
android:layout_marginEnd="@dimen/dimen6dp"
app:cardCornerRadius="@dimen/dimen12dp">
<ImageView
android:id="@+id/commitCommitterAvatar"
<ImageView
android:id="@+id/commitAuthorAvatar"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:contentDescription="@string/generalImgContentText"
tools:srcCompat="@tools:sample/avatars" />
</com.google.android.material.card.MaterialCardView>
<com.google.android.material.card.MaterialCardView
android:id="@+id/commitCommitterAvatarFrame"
android:layout_width="@dimen/dimen24dp"
android:layout_height="@dimen/dimen24dp"
android:layout_marginEnd="5dp"
android:contentDescription="@string/generalImgContentText"
tools:srcCompat="@tools:sample/avatars"/>
style="?attr/materialCardViewFilledStyle"
app:cardElevation="@dimen/dimen0dp"
android:layout_marginEnd="@dimen/dimen6dp"
app:cardCornerRadius="@dimen/dimen12dp">
<ImageView
android:id="@+id/commitCommitterAvatar"
android:layout_width="@dimen/dimen24dp"
android:layout_height="@dimen/dimen24dp"
android:layout_marginEnd="5dp"
android:contentDescription="@string/generalImgContentText"
tools:srcCompat="@tools:sample/avatars"/>
</com.google.android.material.card.MaterialCardView>
<TextView
android:id="@+id/commitAuthorAndCommitter"

View File

@ -48,6 +48,7 @@
tools:ignore="UseCompoundDrawables">
<com.google.android.material.card.MaterialCardView
android:id="@+id/commitAuthorAvatarFrame"
android:layout_width="@dimen/dimen24dp"
android:layout_height="@dimen/dimen24dp"
style="?attr/materialCardViewFilledStyle"
@ -60,17 +61,28 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:contentDescription="@string/generalImgContentText"
tools:srcCompat="@tools:sample/avatars"/>
tools:srcCompat="@tools:sample/avatars" />
</com.google.android.material.card.MaterialCardView>
<ImageView
android:id="@+id/commitCommitterAvatar"
<com.google.android.material.card.MaterialCardView
android:id="@+id/commitCommitterAvatarFrame"
android:layout_width="@dimen/dimen24dp"
android:layout_height="@dimen/dimen24dp"
android:layout_marginEnd="5dp"
android:contentDescription="@string/generalImgContentText"
tools:srcCompat="@tools:sample/avatars"/>
style="?attr/materialCardViewFilledStyle"
app:cardElevation="@dimen/dimen0dp"
android:layout_marginEnd="@dimen/dimen6dp"
app:cardCornerRadius="@dimen/dimen12dp">
<ImageView
android:id="@+id/commitCommitterAvatar"
android:layout_width="@dimen/dimen24dp"
android:layout_height="@dimen/dimen24dp"
android:layout_marginEnd="5dp"
android:contentDescription="@string/generalImgContentText"
tools:srcCompat="@tools:sample/avatars" />
</com.google.android.material.card.MaterialCardView>
<TextView
android:id="@+id/commitAuthorAndCommitter"

View File

@ -27,6 +27,7 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:contentDescription="@string/generalImgContentText"
app:srcCompat="@drawable/ic_diff"/>
@ -61,8 +62,9 @@
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:srcCompat="@drawable/ic_chevron_right"
android:contentDescription="@string/generalImgContentText"/>
android:layout_gravity="center_vertical"
android:contentDescription="@string/generalImgContentText"
app:srcCompat="@drawable/ic_chevron_right" />
</LinearLayout>

View File

@ -4,23 +4,39 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingTop="@dimen/dimen4dp"
android:paddingBottom="@dimen/dimen4dp">
android:orientation="vertical">
<LinearLayout
android:id="@+id/timeline_divider_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingStart="@dimen/dimen12dp"
android:paddingEnd="@dimen/dimen0dp"
android:orientation="vertical">
<FrameLayout
android:id="@+id/timeline_line"
android:layout_width="@dimen/dimen2dp"
android:layout_height="wrap_content"
android:padding="@dimen/dimen8dp"
android:background="?attr/colorPrimary" />
</LinearLayout>
<com.google.android.material.card.MaterialCardView
android:id="@+id/comment_view"
style="?attr/materialCardViewFilledStyle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
style="?attr/materialCardViewFilledStyle"
app:cardElevation="@dimen/dimen0dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:foreground="?android:attr/selectableItemBackground"
android:background="?attr/materialCardBackgroundColor"
android:padding="@dimen/dimen12dp"
android:orientation="vertical">
android:foreground="?android:attr/selectableItemBackground"
android:orientation="vertical"
android:padding="@dimen/dimen12dp">
<LinearLayout
android:layout_width="match_parent"
@ -29,11 +45,11 @@
android:orientation="horizontal">
<com.google.android.material.card.MaterialCardView
style="?attr/materialCardViewFilledStyle"
android:layout_width="@dimen/dimen24dp"
android:layout_height="@dimen/dimen24dp"
style="?attr/materialCardViewFilledStyle"
app:cardElevation="@dimen/dimen0dp"
app:cardCornerRadius="@dimen/dimen12dp">
app:cardCornerRadius="@dimen/dimen12dp"
app:cardElevation="@dimen/dimen0dp">
<ImageView
android:id="@+id/avatar"
@ -41,7 +57,7 @@
android:layout_height="match_parent"
android:layout_weight="0"
android:contentDescription="@string/generalImgContentText"
tools:srcCompat="@tools:sample/avatars"/>
tools:srcCompat="@tools:sample/avatars" />
</com.google.android.material.card.MaterialCardView>
@ -62,7 +78,7 @@
android:singleLine="true"
android:textColor="?attr/primaryTextColor"
android:textSize="14sp"
android:textStyle="bold"/>
android:textStyle="bold" />
<TextView
android:id="@+id/information"
@ -71,7 +87,7 @@
android:ellipsize="end"
android:singleLine="true"
android:textColor="?attr/hintColor"
android:textSize="12sp"/>
android:textSize="12sp" />
</LinearLayout>
<ImageView
@ -80,9 +96,9 @@
android:layout_height="wrap_content"
android:layout_gravity="top"
android:layout_weight="0"
android:contentDescription="@string/menuContentDesc"
android:background="?android:attr/selectableItemBackgroundBorderless"
app:srcCompat="@drawable/ic_dotted_menu_horizontal"/>
android:contentDescription="@string/menuContentDesc"
app:srcCompat="@drawable/ic_dotted_menu_horizontal" />
</LinearLayout>
@ -91,22 +107,85 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="12dp"
android:textColor="?attr/primaryTextColor"
android:textIsSelectable="true"
android:autoLink="web"
android:textColor="?attr/primaryTextColor"
android:textColorLink="@color/lightBlue"
android:textSize="14sp"/>
android:textIsSelectable="true"
android:textSize="14sp" />
<LinearLayout
android:id="@+id/commentReactionBadges"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="gone"
android:layout_marginTop="16dp"
android:orientation="horizontal"/>
android:orientation="horizontal"
android:visibility="gone" />
</LinearLayout>
</com.google.android.material.card.MaterialCardView>
<RelativeLayout
android:id="@+id/timeline_view"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<LinearLayout
android:id="@+id/timeline_divider_view_2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:paddingStart="@dimen/dimen12dp"
android:paddingEnd="@dimen/dimen0dp"
android:orientation="horizontal">
<FrameLayout
android:id="@+id/timeline_line_2"
android:layout_width="@dimen/dimen2dp"
android:layout_height="match_parent"
android:background="?attr/colorPrimary" />
<LinearLayout
android:id="@+id/timeline_data"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:paddingStart="@dimen/dimen16dp"
android:paddingEnd="@dimen/dimen0dp"
android:layout_marginStart="@dimen/dimen6dp"
android:layout_marginEnd="@dimen/dimen4dp"
android:orientation="horizontal" />
</LinearLayout>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:orientation="vertical">
<com.google.android.material.card.MaterialCardView
style="?attr/materialCardViewFilledStyle"
android:layout_width="@dimen/dimen28dp"
android:layout_height="@dimen/dimen28dp"
android:layout_gravity="center_vertical"
android:backgroundTint="?attr/materialCardBackgroundColor"
app:cardCornerRadius="@dimen/dimen6dp"
app:cardElevation="@dimen/dimen0dp">
<ImageView
android:id="@+id/timeline_icon"
android:layout_width="@dimen/dimen16dp"
android:layout_height="@dimen/dimen16dp"
android:layout_gravity="center"
android:contentDescription="@string/generalImgContentText"
android:src="@drawable/ic_history"
tools:srcCompat="@drawable/ic_history" />
</com.google.android.material.card.MaterialCardView>
</LinearLayout>
</RelativeLayout>
</LinearLayout>

View File

@ -61,25 +61,25 @@
android:text="@string/newIssueTitle"
android:textAlignment="gravity"
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"
tools:text="Id illum odio repellat omnis fuga deserunt aut. Ut est aut similique qui incidunt quia et."/>
android:textSize="@dimen/dimen16sp"
tools:text="Id illum odio repellat omnis fuga deserunt aut. Ut est aut similique qui incidunt quia et." />
<HorizontalScrollView
android:id="@+id/labelsScrollViewDots"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/dimen8dp"
android:fillViewport="true"
android:foregroundGravity="right"
android:layout_marginBottom="8dp"
android:scrollbarThumbHorizontal="@android:color/transparent"
android:visibility="gone"
android:fillViewport="true">
android:visibility="gone">
<LinearLayout
android:id="@+id/frameLabelsDots"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginTop="10dp"/>
android:layout_marginTop="@dimen/dimen10dp"
android:orientation="horizontal" />
</HorizontalScrollView>
@ -91,18 +91,18 @@
android:id="@+id/labelsScrollViewWithText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/dimen8dp"
android:fillViewport="true"
android:foregroundGravity="right"
android:layout_marginBottom="8dp"
android:scrollbarThumbHorizontal="@android:color/transparent"
android:visibility="gone"
android:fillViewport="true">
android:visibility="gone">
<LinearLayout
android:id="@+id/frameLabels"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginTop="10dp"/>
android:layout_marginTop="@dimen/dimen10dp"
android:orientation="horizontal" />
</HorizontalScrollView>
@ -119,31 +119,32 @@
android:layout_height="wrap_content"
android:gravity="start"
android:textColor="?attr/hintColor"
android:textSize="12sp"
tools:text="10.01.2020"/>
android:textSize="@dimen/dimen12sp"
tools:text="10.01.2020" />
<LinearLayout
android:id="@+id/frameCommentsCount"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="end"
android:layout_marginStart="10dp"
android:layout_marginEnd="6dp"
android:layout_marginStart="@dimen/dimen10dp"
android:layout_marginEnd="@dimen/dimen6dp"
android:layout_weight="1"
android:gravity="end"
android:orientation="horizontal"
android:paddingLeft="5dp"
android:paddingRight="5dp"
android:paddingLeft="@dimen/dimen4dp"
android:paddingRight="@dimen/dimen4dp"
tools:ignore="UseCompoundDrawables">
<ImageView
android:layout_width="18dp"
android:layout_height="18dp"
android:layout_marginStart="3dp"
android:layout_marginEnd="5dp"
android:id="@+id/comment_icon"
android:layout_width="@dimen/dimen16dp"
android:layout_height="@dimen/dimen16dp"
android:layout_marginStart="@dimen/dimen2dp"
android:layout_marginEnd="@dimen/dimen4dp"
android:contentDescription="@string/generalImgContentText"
app:srcCompat="@drawable/ic_comment"
app:tint="?attr/iconsColor"/>
app:tint="?attr/iconsColor" />
<TextView
android:id="@+id/issueCommentsCount"
@ -152,8 +153,8 @@
android:gravity="center_vertical"
android:text="@string/repoStars"
android:textColor="?attr/primaryTextColor"
android:textSize="14sp"
tools:text="50"/>
android:textSize="@dimen/dimen14sp"
tools:text="50" />
</LinearLayout>

View File

@ -50,7 +50,7 @@
android:layout_weight="0"
android:contentDescription="@string/generalImgContentText"
app:tint="@color/colorWhite"
app:srcCompat="@drawable/ic_label"/>
app:srcCompat="@drawable/ic_tag"/>
<TextView
android:id="@+id/labelName"

View File

@ -9,18 +9,18 @@
android:paddingBottom="@dimen/dimen4dp">
<com.google.android.material.card.MaterialCardView
style="?attr/materialCardViewFilledStyle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
style="?attr/materialCardViewFilledStyle"
app:cardElevation="@dimen/dimen0dp">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:foreground="?android:attr/selectableItemBackground"
android:background="?attr/materialCardBackgroundColor"
android:padding="@dimen/dimen12dp"
android:orientation="vertical">
android:foreground="?android:attr/selectableItemBackground"
android:orientation="vertical"
android:padding="@dimen/dimen12dp">
<LinearLayout
android:id="@+id/org_info_frame"
@ -38,7 +38,7 @@
android:layout_marginStart="@dimen/dimen0dp"
android:layout_marginEnd="@dimen/dimen10dp"
android:contentDescription="@string/repoContentAvatar"
android:src="@drawable/ic_android"/>
android:src="@drawable/ic_android" />
<TextView
android:id="@+id/org_name"
@ -46,7 +46,7 @@
android:layout_height="wrap_content"
android:textColor="?attr/primaryTextColor"
android:textSize="@dimen/dimen14sp"
tools:text="@string/orgName"/>
tools:text="@string/orgName" />
</LinearLayout>
@ -57,13 +57,13 @@
android:text="@string/repoName"
android:textColor="?attr/primaryTextColor"
android:textSize="@dimen/dimen16sp"
android:textStyle="bold"/>
android:textStyle="bold" />
<View
android:id="@+id/spacer_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginBottom="@dimen/dimen8dp"/>
android:layout_marginBottom="@dimen/dimen8dp" />
<LinearLayout
android:id="@+id/repo_info_frame"
@ -78,7 +78,7 @@
android:layout_marginEnd="@dimen/dimen6dp"
android:contentDescription="@string/generalImgContentText"
app:srcCompat="@drawable/ic_trending"
app:tint="?attr/iconsColor"/>
app:tint="?attr/iconsColor" />
<TextView
android:id="@+id/most_visited"
@ -87,7 +87,7 @@
android:gravity="center_vertical"
android:textColor="?attr/primaryTextColor"
android:textSize="@dimen/dimen14sp"
tools:text="@string/repoStars"/>
tools:text="@string/repoStars" />
<LinearLayout
android:id="@+id/repo_info_end_frame"
@ -106,8 +106,8 @@
android:layout_marginStart="@dimen/dimen16dp"
android:layout_marginEnd="@dimen/dimen2dp"
android:contentDescription="@string/generalImgContentText"
app:srcCompat="@drawable/ic_reset"
app:tint="?attr/iconsColor"/>
app:srcCompat="@drawable/ic_delete"
app:tint="?attr/iconsColor" />
</LinearLayout>

View File

@ -44,7 +44,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:contentDescription="@string/generalImgContentText"
android:src="@drawable/ic_android"/>
android:src="@drawable/ic_android" />
</com.google.android.material.card.MaterialCardView>
@ -62,23 +62,23 @@
android:textAlignment="gravity"
android:text="@string/newIssueTitle"
android:textColor="?attr/primaryTextColor"
android:textSize="16sp"/>
android:textSize="@dimen/dimen16sp" />
<HorizontalScrollView
android:id="@+id/labelsScrollViewDots"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/dimen8dp"
android:fillViewport="true"
android:foregroundGravity="right"
android:layout_marginBottom="8dp"
android:scrollbarThumbHorizontal="@android:color/transparent"
android:fillViewport="true">
android:scrollbarThumbHorizontal="@android:color/transparent">
<LinearLayout
android:id="@+id/frameLabelsDots"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginTop="10dp"/>
android:layout_marginTop="@dimen/dimen10dp"
android:orientation="horizontal" />
</HorizontalScrollView>
@ -90,18 +90,18 @@
android:id="@+id/labelsScrollViewWithText"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="@dimen/dimen8dp"
android:fillViewport="true"
android:foregroundGravity="right"
android:layout_marginBottom="8dp"
android:scrollbarThumbHorizontal="@android:color/transparent"
android:visibility="gone"
android:fillViewport="true">
android:visibility="gone">
<LinearLayout
android:id="@+id/frameLabels"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:layout_marginTop="10dp"/>
android:layout_marginTop="@dimen/dimen10dp"
android:orientation="horizontal" />
</HorizontalScrollView>
@ -118,27 +118,28 @@
android:layout_height="wrap_content"
android:gravity="start"
android:textColor="?attr/hintColor"
android:textSize="12sp"/>
android:textSize="@dimen/dimen12sp" />
<LinearLayout
android:id="@+id/frameCommentsCount"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="end"
android:layout_marginStart="10dp"
android:layout_marginEnd="6dp"
android:layout_marginStart="@dimen/dimen10dp"
android:layout_marginEnd="@dimen/dimen6dp"
android:layout_weight="1"
android:gravity="end"
android:orientation="horizontal"
android:paddingLeft="5dp"
android:paddingRight="5dp"
android:paddingLeft="@dimen/dimen4dp"
android:paddingRight="@dimen/dimen4dp"
tools:ignore="UseCompoundDrawables">
<ImageView
android:layout_width="18dp"
android:layout_height="18dp"
android:layout_marginStart="3dp"
android:layout_marginEnd="5dp"
android:id="@+id/comment_icon"
android:layout_width="@dimen/dimen16dp"
android:layout_height="@dimen/dimen16dp"
android:layout_marginStart="@dimen/dimen2dp"
android:layout_marginEnd="@dimen/dimen4dp"
android:contentDescription="@string/generalImgContentText"
app:srcCompat="@drawable/ic_comment"
app:tint="?attr/iconsColor"/>
@ -150,7 +151,7 @@
android:gravity="center_vertical"
android:text="@string/repoStars"
android:textColor="?attr/primaryTextColor"
android:textSize="14sp"/>
android:textSize="@dimen/dimen14sp" />
</LinearLayout>

View File

@ -130,7 +130,7 @@
android:layout_width="@dimen/dimen18dp"
android:layout_height="wrap_content"
android:contentDescription="@string/generalImgContentText"
app:srcCompat="@drawable/ic_label" />
app:srcCompat="@drawable/ic_tag" />
<TextView
android:id="@+id/releaseTag"

View File

@ -4,9 +4,9 @@
<item
android:id="@+id/reset_menu_item"
android:icon="@drawable/ic_reset"
android:title="@string/menuContentDesc"
android:icon="@drawable/ic_delete"
android:orderInCategory="1"
app:showAsAction="ifRoom"/>
android:title="@string/menuContentDesc"
app:showAsAction="ifRoom" />
</menu>

View File

@ -790,4 +790,45 @@
<string name="sourcePosition" translatable="false">%1$d:%2$d</string>
<string name="codeEditor" translatable="false">Code Editor</string>
<string name="openInCodeEditor">Open in Code Editor</string>
<!-- timeline -->
<string name="timelineAddedLabelStart">%s added the\u0020</string>
<string name="timelineRemovedLabelStart">%s removed the\u0020</string>
<string name="timelineLabelEnd">\u0020label %s</string>
<string name="timelineAddedCommit">%s added\u0020</string>
<string name="timelineAssigneesRemoved">%s removed their assignment %s</string>
<string name="timelineAssigneesUnassigned">%s was unassigned by %s %s</string>
<string name="timelineAssigneesSelfAssigned">%s self-assigned this %s</string>
<string name="timelineAssigneesAssigned">%s was assigned by %s %s</string>
<string name="timelineMilestoneAdded">%s added this to the %s milestone %s</string>
<string name="timelineMilestoneRemoved">%s removed this from the %s milestone %s</string>
<string name="timelineStatusClosedIssue">%s closed this issue %s</string>
<string name="timelineStatusReopenedIssue">%s reopened this issue %s</string>
<string name="timelineStatusRefIssue">%s referenced this issue from a \u0020</string>
<string name="timelineStatusClosedPr">%s closed this pull request %s</string>
<string name="timelineStatusMergedPr">%s merged this pull request %s</string>
<string name="timelineStatusRefPr">%s referenced this pull request from a\u0020</string>
<string name="commitText">commit</string>
<string name="timelineStatusReopenedPr">%s reopened this pull request %s</string>
<string name="timelineReviewRequest">%s requested review from %s %s</string>
<string name="timelineChangeTitle">%s changed title from %s to %s %s</string>
<string name="timelineLocked">%s locked as %s and limited conversation to collaborators %s</string>
<string name="timelineUnlocked">%s unlocked this conversation %s</string>
<string name="timelineDependencyAdded">%s added a new dependency #%d %s</string>
<string name="timelineDependencyRemoved">%s removed a dependency #%d %s</string>
<string name="timelineProjectAdded">%s added this to a project %s</string>
<string name="timelineProjectRemoved">%s removed this from a project %s</string>
<string name="timelineDueDateAdded">%s added the due date %s %s</string>
<string name="timelineDueDateModified">%s modified the due date to %s from %s %s</string>
<string name="timelineDueDateRemoved">%s removed the due date %s %s</string>
<string name="timelineBranchChanged">%s changed target branch from %s to %s %s</string>
<string name="timelineBranchDeleted">%s deleted branch %s %s</string>
<string name="timelineTimeTrackingStart">%s started working %s</string>
<string name="timelineTimeTrackingStop">%s stopped time tracking %s</string>
<string name="timelineTimeTrackingCancel">%s cancelled time tracking %s</string>
<string name="timelineTimeTrackingAddManualTime">%s added spent time %s %s</string>
<string name="timelineTimeTrackingDeleteManualTime">%s deleted spent time %s %s</string>
<string name="timelineChangeIssueRef">%s added reference %s %s</string>
<string name="timelineRefIssue">%s referenced this issue in #%d %s</string>
<string name="timelineRefPr">%s referenced this pull request in #%d %s</string>
</resources>