1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-04 08:28:11 +00:00

search type add enter icon (#6281)

This commit is contained in:
Michael An
2024-07-02 10:26:04 +08:00
committed by GitHub
parent 261fa44564
commit 14c2186bcb
10 changed files with 43 additions and 7 deletions

View File

@@ -460,6 +460,7 @@ export default class AISearch extends Component {
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in all libraries')}</span>
<i className="sf3-font sf3-font-enter"></i>
</div>
</div>
{resultItems.length > 0 && (
@@ -493,16 +494,19 @@ export default class AISearch extends Component {
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in this library')}</span>
{highlightIndex === 0 && <i className="sf3-font sf3-font-enter"></i>}
</div>
<div className={`search-types-folder ${highlightIndex === 1 ? 'search-types-highlight' : ''}`} onClick={this.searchFolder} tabIndex={0}>
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in this folder')}</span>
{highlightIndex === 1 && <i className="sf3-font sf3-font-enter"></i>}
</div>
<div className={`search-types-repos ${highlightIndex === 2 ? 'search-types-highlight' : ''}`} onClick={this.searchAllRepos} tabIndex={0}>
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in all libraries')}</span>
{highlightIndex === 2 && <i className="sf3-font sf3-font-enter"></i>}
</div>
</div>
);
@@ -513,11 +517,13 @@ export default class AISearch extends Component {
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in this library')}</span>
{highlightIndex === 0 && <i className="sf3-font sf3-font-enter"></i>}
</div>
<div className={`search-types-repos ${highlightIndex === 1 ? 'search-types-highlight' : ''}`} onClick={this.searchAllRepos} tabIndex={0}>
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in all libraries')}</span>
{highlightIndex === 1 && <i className="sf3-font sf3-font-enter"></i>}
</div>
</div>
);

View File

@@ -459,6 +459,7 @@ class Search extends Component {
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in all libraries')}</span>
<i className="sf3-font sf3-font-enter"></i>
</div>
</div>
{resultItems.length > 0 && (
@@ -492,16 +493,19 @@ class Search extends Component {
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in this library')}</span>
{highlightIndex === 0 && <i className="sf3-font sf3-font-enter"></i>}
</div>
<div className={`search-types-folder ${highlightIndex === 1 ? 'search-types-highlight' : ''}`} onClick={this.searchFolder} tabIndex={0}>
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in this folder')}</span>
{highlightIndex === 1 && <i className="sf3-font sf3-font-enter"></i>}
</div>
<div className={`search-types-repos ${highlightIndex === 2 ? 'search-types-highlight' : ''}`} onClick={this.searchAllRepos} tabIndex={0}>
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in all libraries')}</span>
{highlightIndex === 2 && <i className="sf3-font sf3-font-enter"></i>}
</div>
</div>
);
@@ -512,11 +516,13 @@ class Search extends Component {
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in this library')}</span>
{highlightIndex === 0 && <i className="sf3-font sf3-font-enter"></i>}
</div>
<div className={`search-types-repos ${highlightIndex === 1 ? 'search-types-highlight' : ''}`} onClick={this.searchAllRepos} tabIndex={0}>
<i className="search-icon-left input-icon-addon sf3-font sf3-font-search"></i>
{inputValue}
<span className="search-types-text">{gettext('in all libraries')}</span>
{highlightIndex === 1 && <i className="sf3-font sf3-font-enter"></i>}
</div>
</div>
);

View File

@@ -411,6 +411,12 @@
color: #666;
}
.search-types .sf3-font-enter {
position: absolute;
right: 6px;
color: #999999;
}
.library-result-container {
margin-bottom: 16px;
}

View File

@@ -1,11 +1,11 @@
@font-face {
font-family: "sf3-font"; /* Project id 1230969 */
src: url('iconfont.eot?t=1719381808514'); /* IE9 */
src: url('iconfont.eot?t=1719381808514#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('iconfont.woff2?t=1719381808514') format('woff2'),
url('iconfont.woff?t=1719381808514') format('woff'),
url('iconfont.ttf?t=1719381808514') format('truetype'),
url('iconfont.svg?t=1719381808514#sf3-font') format('svg');
src: url('iconfont.eot?t=1719885081769'); /* IE9 */
src: url('iconfont.eot?t=1719885081769#iefix') format('embedded-opentype'), /* IE6-IE8 */
url('iconfont.woff2?t=1719885081769') format('woff2'),
url('iconfont.woff?t=1719885081769') format('woff'),
url('iconfont.ttf?t=1719885081769') format('truetype'),
url('iconfont.svg?t=1719885081769#sf3-font') format('svg');
}
.sf3-font {
@@ -16,6 +16,18 @@
-moz-osx-font-smoothing: grayscale;
}
.sf3-font-enter:before {
content: "\e845";
}
.sf3-font-open-sidebar:before {
content: "\e843";
}
.sf3-font-close-sidebar:before {
content: "\e844";
}
.sf3-font-exclamation-triangle:before {
content: "\e840";
}

Binary file not shown.

File diff suppressed because one or more lines are too long

View File

@@ -14,6 +14,12 @@
/>
<missing-glyph />
<glyph glyph-name="enter" unicode="&#59461;" d="M912 768c25.6 0 48-25.6 48-48V288c0-54.4-41.6-96-96-96H240l124.8-124.8c19.2-19.2 19.2-51.2 3.2-73.6-19.2-22.4-51.2-22.4-70.4-6.4l-6.4 3.2-211.2 211.2c-19.2 19.2-19.2 54.4 0 73.6l211.2 211.2c19.2 19.2 51.2 19.2 73.6 3.2 22.4-19.2 22.4-51.2 6.4-70.4l-6.4-3.2-124.8-128H832c19.2 0 32 12.8 32 32V720c0 28.8 19.2 48 48 48z" horiz-adv-x="1024" />
<glyph glyph-name="open-sidebar" unicode="&#59459;" d="M464 819.2c-19.2-19.2-19.2-48 0-67.2L838.4 384 464 16c-16-16-16-48 0-67.2 9.6-9.6 22.4-12.8 35.2-12.8 12.8 0 25.6 6.4 35.2 12.8L944 352c9.6 9.6 16 22.4 16 35.2 0 12.8-6.4 25.6-16 35.2L534.4 819.2c-19.2 16-48 16-70.4 0z m-384 0c-22.4-19.2-22.4-51.2 0-70.4L451.2 384 80 16c-19.2-19.2-19.2-48 0-67.2 6.4-6.4 19.2-12.8 35.2-12.8 12.8 0 25.6 6.4 35.2 12.8L560 352c9.6 9.6 16 22.4 16 35.2 0 12.8-6.4 25.6-16 35.2L150.4 819.2c-22.4 16-51.2 16-70.4 0z" horiz-adv-x="1024" />
<glyph glyph-name="close-sidebar" unicode="&#59460;" d="M560 819.2c19.2-19.2 19.2-48 0-67.2L185.6 384l371.2-368c19.2-19.2 19.2-48 0-67.2-9.6-9.6-22.4-12.8-35.2-12.8-12.8 0-25.6 6.4-35.2 12.8L80 352c-9.6 6.4-16 19.2-16 32s6.4 25.6 16 35.2L489.6 819.2c19.2 16 48 16 70.4 0z m384 0c19.2-19.2 19.2-48 0-67.2L572.8 384l371.2-368c19.2-19.2 19.2-48 0-67.2-9.6-9.6-22.4-12.8-35.2-12.8-12.8 0-25.6 6.4-35.2 12.8L464 352c-9.6 9.6-16 22.4-16 35.2 0 12.8 6.4 25.6 16 35.2L873.6 819.2c22.4 16 51.2 16 70.4 0z" horiz-adv-x="1024" />
<glyph glyph-name="exclamation-triangle" unicode="&#59456;" d="M513.23328 832c12.8 0 25.6-3.2 38.4-9.6 12.8-6.4 19.2-16 25.6-28.8l438.4-748.8c12.8-25.6 12.8-48 0-70.4-6.4-9.6-16-19.2-25.6-25.6-12.8-6.4-22.4-9.6-35.2-9.6H71.63328c-12.8 0-25.6 3.2-35.2 9.6-9.6 6.4-19.2 16-25.6 25.6-12.8 25.6-16 48 0 70.4L449.23328 793.6c6.4 12.8 16 22.4 25.6 28.8 12.8 6.4 25.6 9.6 38.4 9.6z m0-640c-44.8 0-80-35.2-80-80S468.43328 32 513.23328 32s80 35.2 80 80S558.03328 192 513.23328 192z m64 352h-124.8c-6.4 0-9.6 0-12.8-3.2-3.2-3.2-6.4-6.4-6.4-9.6l9.6-265.6c0-3.2 3.2-6.4 6.4-9.6 3.2-3.2 9.6-3.2 12.8-3.2h102.4c6.4 0 9.6 0 12.8 3.2 6.4 3.2 6.4 6.4 6.4 9.6l9.6 265.6c0 3.2-3.2 6.4-6.4 9.6-3.2 3.2-6.4 3.2-9.6 3.2z" horiz-adv-x="1025" />
<glyph glyph-name="check-circle" unicode="&#59457;" d="M992 384c0-265.6-214.4-480-480-480S32 118.39999999999998 32 384 246.4 864 512 864s480-214.4 480-480z m-534.4-252.8l355.2 355.2c6.4 6.4 9.6 12.8 9.6 22.4 0 9.6-3.2 16-9.6 22.4L768 572.8c-6.4 6.4-12.8 9.6-22.4 9.6s-16-3.2-22.4-9.6l-291.2-291.2-137.6 137.6c-6.4 6.4-12.8 9.6-22.4 9.6s-12.8-3.2-16-9.6l-44.8-44.8c-6.4-6.4-9.6-12.8-9.6-22.4 0-9.6 3.2-16 9.6-22.4l201.6-201.6c6.4-6.4 12.8-9.6 22.4-9.6 6.4 3.2 16 6.4 22.4 12.8z" horiz-adv-x="1024" />

Before

Width:  |  Height:  |  Size: 67 KiB

After

Width:  |  Height:  |  Size: 69 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.