Skip to content

A Q&A platform software for teams at any scales. Whether it's a community forum, help center, or knowledge management platform, you can always count on Apache Answer.

fix(Personal): Remove the background color of all Tabs on personal home page

haitao(lj)77274fd66cf0
diff --git a/ui/config-overrides.js b/ui/config-overrides.js
index 3d70e9e4..60b66a51 100644
--- a/ui/config-overrides.js
+++ b/ui/config-overrides.js
@@ -29,18 +29,18 @@ module.exports = {
devServer: function(configFunction) {
return function(proxy, allowedHost) {
const config = configFunction(proxy, allowedHost);
- config.proxy = {
- '/answer': {
+ config.proxy = [
+ {
+ context: ['/answer', '/installation'],
target: process.env.REACT_APP_API_URL,
changeOrigin: true,
secure: false,
},
- '/installation': {
+ {
+ context: ['/custom.css'],
target: process.env.REACT_APP_API_URL,
- changeOrigin: true,
- secure: false,
- },
- };
+ }
+ ];
return config;
};
}
diff --git a/ui/src/pages/Users/Personal/components/Answers/index.tsx b/ui/src/pages/Users/Personal/components/Answers/index.tsx
index 1a37535e..7ddd1820 100644
--- a/ui/src/pages/Users/Personal/components/Answers/index.tsx
+++ b/ui/src/pages/Users/Personal/components/Answers/index.tsx
@@ -18,7 +18,9 @@ const Index: FC<Props> = ({ visible, data }) => {
<ListGroup variant="flush">
{data.map((item) => {
return (
- <ListGroupItem className="py-3 px-0" key={item.answer_id}>
+ <ListGroupItem
+ className="py-3 px-0 bg-transparent"
+ key={item.answer_id}>
<h6 className="mb-2">
<a
href={pathFactory.answerLanding({
diff --git a/ui/src/pages/Users/Personal/components/Comments/index.tsx b/ui/src/pages/Users/Personal/components/Comments/index.tsx
index 7422db7f..cefdbf94 100644
--- a/ui/src/pages/Users/Personal/components/Comments/index.tsx
+++ b/ui/src/pages/Users/Personal/components/Comments/index.tsx
@@ -17,7 +17,9 @@ const Index: FC<Props> = ({ visible, data }) => {
<ListGroup variant="flush">
{data.map((item) => {
return (
- <ListGroupItem className="py-3 px-0" key={item.comment_id}>
+ <ListGroupItem
+ className="py-3 px-0 bg-transparent"
+ key={item.comment_id}>
<a
className="text-break"
href={
diff --git a/ui/src/pages/Users/Personal/components/DefaultList/index.tsx b/ui/src/pages/Users/Personal/components/DefaultList/index.tsx
index 485935e2..db585f18 100644
--- a/ui/src/pages/Users/Personal/components/DefaultList/index.tsx
+++ b/ui/src/pages/Users/Personal/components/DefaultList/index.tsx
@@ -22,7 +22,7 @@ const Index: FC<Props> = ({ visible, tabName, data }) => {
{data.map((item) => {
return (
<ListGroupItem
- className="py-3 px-0"
+ className="py-3 px-0 bg-transparent"
key={tabName === 'questions' ? item.question_id : item.id}>
<h6 className="mb-2">
<a
diff --git a/ui/src/pages/Users/Personal/components/Reputation/index.tsx b/ui/src/pages/Users/Personal/components/Reputation/index.tsx
index 104b3f8c..b4e82f32 100644
--- a/ui/src/pages/Users/Personal/components/Reputation/index.tsx
+++ b/ui/src/pages/Users/Personal/components/Reputation/index.tsx
@@ -19,7 +19,9 @@ const Index: FC<Props> = ({ visible, data }) => {
<ListGroup variant="flush">
{data.map((item) => {
return (
- <ListGroupItem className="d-flex py-3 px-0" key={item.object_id}>
+ <ListGroupItem
+ className="d-flex py-3 px-0 bg-transparent"
+ key={item.object_id}>
<div
className={`me-3 text-end ${
item.reputation > 0 ? 'text-success' : 'text-danger'
diff --git a/ui/src/pages/Users/Personal/components/Votes/index.tsx b/ui/src/pages/Users/Personal/components/Votes/index.tsx
index 5cf369dd..65d09b01 100644
--- a/ui/src/pages/Users/Personal/components/Votes/index.tsx
+++ b/ui/src/pages/Users/Personal/components/Votes/index.tsx
@@ -18,7 +18,9 @@ const Index: FC<Props> = ({ visible, data }) => {
<ListGroup variant="flush">
{data.map((item) => {
return (
- <ListGroupItem className="d-flex py-3 px-0" key={item.object_id}>
+ <ListGroupItem
+ className="d-flex py-3 px-0 bg-transparent"
+ key={item.object_id}>
<div
className="me-3 text-end text-secondary flex-shrink-0"
style={{ width: '80px' }}>