You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@answer.apache.org by sh...@apache.org on 2024/07/24 04:00:33 UTC

(incubator-answer) branch test updated (0f95078a -> eeef73b3)

This is an automated email from the ASF dual-hosted git repository.

shuai pushed a change to branch test
in repository https://gitbox.apache.org/repos/asf/incubator-answer.git


    from 0f95078a fix: Fix typo in delete tag confirmation message
     new 2ef53f32 fix: aks page init formdata
     new a3237524 fix: add front-matter licesnse
     new 3ff3d3e4 feat: add serch icon #1010
     new eeef73b3 fix: the images in the image upload component are forced to enlarge #1039

The 4 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 docs/release/LICENSE                                      |  1 +
 ...SE-Bunlong-next-share.txt => LICENSE-front-matter.txt} |  4 ++--
 ui/src/components/BrandUpload/index.tsx                   |  3 +--
 ui/src/components/Header/index.scss                       | 15 +++++++++++++++
 ui/src/components/Header/index.tsx                        |  6 +++++-
 ui/src/pages/Questions/Ask/index.tsx                      |  3 +--
 6 files changed, 25 insertions(+), 7 deletions(-)
 copy docs/release/licenses/{LIcENSE-Bunlong-next-share.txt => LICENSE-front-matter.txt} (94%)


(incubator-answer) 03/04: feat: add serch icon #1010

Posted by sh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

shuai pushed a commit to branch test
in repository https://gitbox.apache.org/repos/asf/incubator-answer.git

commit 3ff3d3e4522d54bad269d879d6111107f488f16e
Author: shuai <li...@sifou.com>
AuthorDate: Tue Jul 23 10:51:04 2024 +0800

    feat: add serch icon #1010
---
 ui/src/components/Header/index.scss | 15 +++++++++++++++
 ui/src/components/Header/index.tsx  |  6 +++++-
 2 files changed, 20 insertions(+), 1 deletion(-)

diff --git a/ui/src/components/Header/index.scss b/ui/src/components/Header/index.scss
index 1a02c332..d0ee60c8 100644
--- a/ui/src/components/Header/index.scss
+++ b/ui/src/components/Header/index.scss
@@ -55,6 +55,7 @@
   // style for colored navbar
   &.theme-colored {
     .placeholder-search {
+      padding-left: 42px;
       box-shadow: none;
       color: #fff;
       background-color: rgba(255, 255, 255, .2);
@@ -66,6 +67,9 @@
         color: rgba(255, 255, 255, 0.75);
       }
     }
+    .search-icon {
+      color: #fff;
+    }
   }
 
   // style for colored navbar
@@ -75,6 +79,7 @@
       color: rgba(0, 0, 0, 0.65);
     }
     .placeholder-search {
+      padding-left: 42px;
       box-shadow: none;
       color: var(--bs-body-color);
       background-color: rgba(255, 255, 255, .2);
@@ -86,11 +91,21 @@
         color: rgba(0, 0, 0, 0.65);
       }
     }
+    .search-icon {
+      color: var(--bs-body-color);
+    }
   }
 
   .maxw-400 {
     max-width: 400px;;
   }
+
+  .search-wrap {
+    position: absolute;
+    top: 0;
+    left: 0;
+    padding: 0.5rem 1rem;
+  }
 }
 
 
diff --git a/ui/src/components/Header/index.tsx b/ui/src/components/Header/index.tsx
index 2757f6c1..28e8370f 100644
--- a/ui/src/components/Header/index.tsx
+++ b/ui/src/components/Header/index.tsx
@@ -47,6 +47,7 @@ import {
   sideNavStore,
 } from '@/stores';
 import { logout, useQueryNotificationStatus } from '@/services';
+import { Icon } from '@/components';
 
 import NavItems from './components/NavItems';
 
@@ -205,8 +206,11 @@ const Header: FC = () => {
           <Col lg={8} className="ps-0">
             <Form
               action="/search"
-              className="w-100 maxw-400"
+              className="w-100 maxw-400 position-relative"
               onSubmit={handleSearch}>
+              <div className="search-wrap" onClick={handleSearch}>
+                <Icon name="search" className="search-icon" />
+              </div>
               <FormControl
                 type="search"
                 placeholder={t('header.search.placeholder')}


(incubator-answer) 02/04: fix: add front-matter licesnse

Posted by sh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

shuai pushed a commit to branch test
in repository https://gitbox.apache.org/repos/asf/incubator-answer.git

commit a32375243f4738db1f3d4e16144a8c33f950c358
Author: shuai <li...@sifou.com>
AuthorDate: Thu Jul 18 15:41:31 2024 +0800

    fix: add front-matter licesnse
---
 docs/release/LICENSE                           | 1 +
 docs/release/licenses/LICENSE-front-matter.txt | 9 +++++++++
 2 files changed, 10 insertions(+)

diff --git a/docs/release/LICENSE b/docs/release/LICENSE
index 3ad83d98..26c12b2b 100644
--- a/docs/release/LICENSE
+++ b/docs/release/LICENSE
@@ -272,6 +272,7 @@ The following components are provided under the MIT License. See project link fo
    (MIT License) tidwall-gjson (https://github.com/tidwall/gjson) [link](./licenses/LICENSE-tidwall-gjson.txt)
    (MIT License) yuin-goldmark (https://github.com/yuin/goldmark) [link](./licenses/LICENSE-yuin-goldmark.txt)
    (MIT License) go-gomail-gomail (https://gopkg.in/gomail.v2) [link](./licenses/LICENSE-go-gomail-gomail.txt)
+   (MIT License) front-matter (https://github.com/jxson/front-matter) [link](./licenses/LICENSE-front-matter.txt)
 
 ========================================================================
 BSD licenses
diff --git a/docs/release/licenses/LICENSE-front-matter.txt b/docs/release/licenses/LICENSE-front-matter.txt
new file mode 100644
index 00000000..377f5461
--- /dev/null
+++ b/docs/release/licenses/LICENSE-front-matter.txt
@@ -0,0 +1,9 @@
+# The MIT License (MIT)
+
+Copyright (c) Jason Campbell ("Author")
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


(incubator-answer) 04/04: fix: the images in the image upload component are forced to enlarge #1039

Posted by sh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

shuai pushed a commit to branch test
in repository https://gitbox.apache.org/repos/asf/incubator-answer.git

commit eeef73b3c3993416043c5d2182fe2ae4ba334914
Author: shuai <li...@sifou.com>
AuthorDate: Wed Jul 24 10:57:04 2024 +0800

    fix: the images in the image upload component are forced to enlarge #1039
---
 ui/src/components/BrandUpload/index.tsx | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/ui/src/components/BrandUpload/index.tsx b/ui/src/components/BrandUpload/index.tsx
index 34fcd73b..cf92d46e 100644
--- a/ui/src/components/BrandUpload/index.tsx
+++ b/ui/src/components/BrandUpload/index.tsx
@@ -56,8 +56,7 @@ const Index: FC<Props> = ({
           className={classNames(imgClassNames)}
           src={value}
           alt=""
-          height="100%"
-          width="100%"
+          style={{ maxWidth: '100%', maxHeight: '100%' }}
         />
       </div>
       <ButtonGroup vertical className="fit-content">


(incubator-answer) 01/04: fix: aks page init formdata

Posted by sh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

shuai pushed a commit to branch test
in repository https://gitbox.apache.org/repos/asf/incubator-answer.git

commit 2ef53f32e0d23802aeac961a07f31be7e896afdf
Author: shuai <li...@sifou.com>
AuthorDate: Tue Jul 16 17:40:18 2024 +0800

    fix: aks page init formdata
---
 ui/src/pages/Questions/Ask/index.tsx | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/ui/src/pages/Questions/Ask/index.tsx b/ui/src/pages/Questions/Ask/index.tsx
index f9517936..fe6afd69 100644
--- a/ui/src/pages/Questions/Ask/index.tsx
+++ b/ui/src/pages/Questions/Ask/index.tsx
@@ -147,7 +147,6 @@ const Ask = () => {
           const file = fm<any>(decodeURIComponent(prefill));
           formData.title.value = file.attributes?.title;
           formData.content.value = file.body;
-          setFormData({ ...formData });
           if (!queryTags && file.attributes?.tags) {
             updateTags(file.attributes.tags);
           }
@@ -158,8 +157,8 @@ const Ask = () => {
           formData.answer_content.value = draft.answer_content;
           setCheckState(Boolean(draft.answer_content));
           setHasDraft(true);
-          setFormData({ ...formData });
         }
+        setFormData({ ...formData });
       } else {
         resetForm();
       }