Skip to content

Commit 1717c02

Browse files
committed
chore: 文档国际化
1 parent 1737291 commit 1717c02

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+583
-566
lines changed

.DS_Store

0 Bytes
Binary file not shown.

.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,7 @@
22
node_modules
33

44
.DS_Store
5-
deploy.tar.gz
5+
deploy.tar.gz
6+
7+
8+
.env

components/contributors/index.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,11 @@ const contributors: Contributor[] = [
4040
avatar: "/avatars/jieyangxchen.jpeg",
4141
github: "https://github.com/jieyangxchen",
4242
},
43+
{
44+
name: "张国权",
45+
avatar: "/avatars/zgq.jpg",
46+
github: "https://github.com/openai0229",
47+
},
4348
];
4449

4550
export const Contributors: React.FC = () => {

pages/en-US/contact.mdx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,12 @@ If you encounter any issues while using FastExcel, or have any suggestions, feel
1515
- Participate in [Discussions](https://github.com/CodePhiliaX/fastexcel/discussions)
1616

1717
### Contribution Guidelines
18+
1819
If you would like to contribute to FastExcel, please refer to our [Contribution Guidelines](/zh-CN/docs/contribution).
1920

2021
### Stay Updated
21-
Follow the WeChat official account of the author "CodePhiliaX" for more technical content and the latest updates.
22+
23+
Follow the WeChat official account of the author "Lazy Coder" for more technical content and the latest updates.
2224

2325
<div style={{maxWidth: '500px'}}>
2426
![Contact Us](/images/docs/contact_wechat.jpg)

pages/en-US/docs/FAQ.mdx

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9,47 +9,47 @@ description: Frequently Asked Questions
99

1010
#### Choosing Write Operations
1111
- **Q:** When writing to Excel, when should I choose the fill mode and when should I choose direct writing?
12-
- **A:** For complex formatted export content, it is recommended to use template filling; for simple formatted scenarios, direct writing is more efficient.
12+
- **A:** For complex export content, it is recommended to use template filling; for simple format scenarios, direct writing is more efficient.
1313

1414
#### Lombok Annotations
1515
- **Q:** What is the role of Lombok annotations in using FastExcel?
1616
- **A:** Commonly used Lombok annotations in entity classes such as `@Getter`, `@Setter`, `@EqualsAndHashCode` are used to automatically generate getter, setter methods, equals, and hashCode methods. If you do not want to use these auto-generated methods, you can implement them yourself.
1717

1818
#### Field Matching
1919
- **Q:** How to solve the problem of some fields not being read or written correctly?
20-
- **A:** Ensure that the entity class fields follow the camel case naming convention, avoid using `@Accessors(chain = true)`, and recommend using `@Builder` instead. Also, ensure that the entity class uses the `@ExcelProperty` annotation to mark the fields involved in reading and writing.
20+
- **A:** Ensure that the entity class fields follow the camel case naming convention, avoid using `@Accessors(chain = true)`, and recommend using `@Builder` instead. Also, ensure that the entity class uses the `@ExcelProperty` annotation to mark the fields participating in reading and writing.
2121

2222
#### Compatibility Issues
2323
- **Q:** What should I do if I encounter compatibility issues when using FastExcel?
24-
- **A:** Common compatibility issues include `NoSuchMethodException`, `ClassNotFoundException`, `NoClassDefFoundError`, etc., usually caused by jar conflicts. It is recommended to check and clean up dependencies in the project to ensure that the FastExcel version used is compatible with other libraries in the project.
24+
- **A:** Common compatibility issues include `NoSuchMethodException`, `ClassNotFoundException`, `NoClassDefFoundError`, etc., usually caused by jar conflicts. It is recommended to check and clean up dependencies in the project to ensure that the version of FastExcel used is compatible with other libraries in the project.
2525

2626
#### Online Deployment
27-
- **Q:** Why are there problems in the online environment when running normally locally?
27+
- **Q:** Why are there issues in the online environment when it runs fine locally?
2828
- **A:** In most cases, this is due to the lack of necessary font libraries in the online environment. You can solve this problem by installing font libraries (such as `dejavu-sans-fonts` and `fontconfig`) or enabling memory processing mode.
2929

3030
#### Concurrent Reading
3131
- **Q:** Why shouldn't the Listener be managed by Spring?
32-
- **A:** Listeners should not be managed by Spring because this would cause the Listener to become a singleton, which may lead to data confusion issues when concurrently reading files. A new Listener instance should be created each time a file is read.
32+
- **A:** Listeners should not be managed by Spring because this would cause the Listener to become a singleton, which may lead to data confusion when reading files concurrently. A new Listener instance should be created each time a file is read.
3333

3434
#### Performance Optimization
3535
- **Q:** For large files over 10M, what reading strategies does FastExcel provide?
3636
- **A:** FastExcel supports default large file processing strategies, as well as customizable high-speed modes and optimization settings for high concurrency and super large files.
3737

3838
#### Writing and Format Setting
3939
- **Q:** How to set cell formats?
40-
- **A:** You can set cell formats by using annotations like `@ContentStyle` on entity class properties, such as numeric formats, date formats, etc.
40+
- **A:** You can set cell formats by using annotations such as `@ContentStyle` on entity class properties, for example, numeric formats, date formats, etc.
4141

4242
#### Export Issues
43-
- **Q:** How to solve the problem when the exported Excel file cannot be opened or prompts for repair?
44-
- **A:** This is usually caused by frontend frameworks or backend interceptors modifying the file stream. It is recommended to test local exports first, ensure the correctness of backend logic, and then investigate frontend and network-related issues.
43+
- **Q:** How to resolve the issue of Excel files exported cannot be opened or prompt for repair?
44+
- **A:** This is usually caused by frontend frameworks or backend interceptors modifying the file stream. It is recommended to test local exports first, ensure the backend logic is correct, and then investigate frontend and network-related issues.
4545

4646
#### Large File Reading Optimization
4747
- **Q:** How does FastExcel optimize memory usage when reading large files?
4848
- **A:** FastExcel automatically determines the processing method for large files. For files with shared strings exceeding 5MB, a file storage strategy is used to reduce memory usage. You can enable ultra-fast mode by setting the `readCache` parameter, but this will increase memory consumption.
4949

5050
#### Concurrent Processing
5151
- **Q:** How to efficiently read Excel files in a high-concurrency environment?
52-
- **A:** In a high-concurrency environment, you can optimize reading performance using `SimpleReadCacheSelector`. By setting parameters like `maxUseMapCacheSize` and `maxCacheActivateBatchCount`, you can control the cache strategy for shared strings, improve hit rate, and reduce file read latency.
52+
- **A:** In a high-concurrency environment, you can optimize reading performance using `SimpleReadCacheSelector`. By setting the `maxUseMapCacheSize` and `maxCacheActivateBatchCount` parameters, you can control the cache strategy for shared strings, improve hit rates, and reduce file read delays.
5353

5454
#### Field Mapping
5555
- **Q:** How to handle cases where entity class fields do not match Excel column names?
@@ -90,15 +90,15 @@ description: Frequently Asked Questions
9090
```
9191

9292
#### Fill Mode
93-
- **Q:** How to solve the problem of fields not being replaced in fill mode?
94-
- **A:** Using the `inMemory(true)` parameter can ensure that fields are correctly replaced. For example:
93+
- **Q:** How to solve the issue of fields not being replaced in fill mode?
94+
- **A:** Using the `inMemory(true)` parameter can ensure correct field replacement. For example:
9595
```java
9696
FastExcel.write(fileName, DemoData.class).inMemory(true).sheet("Template").doWrite(fillData());
9797
```
9898

9999
#### CSV Separator
100-
- **Q:** How to modify the separator of a CSV file?
101-
- **A:** You can modify the separator of a CSV file by setting `CsvFormat`. For example:
100+
- **Q:** How to modify the CSV file separator?
101+
- **A:** You can modify the CSV file separator by setting `CsvFormat`. For example:
102102
```java
103103
try (ExcelReader excelReader = FastExcel.read(fileName, DemoData.class, new DemoDataListener()).build()) {
104104
ReadWorkbookHolder readWorkbookHolder = excelReader.analysisContext().readWorkbookHolder();
@@ -129,7 +129,7 @@ description: Frequently Asked Questions
129129

130130
#### Dependency Conflict
131131
- **Q:** How to resolve dependency conflict issues?
132-
- **A:** Common dependency conflicts include POI, ehcache, commons-io, etc. It is recommended to check the dependency tree in the project to ensure that the versions used are compatible with FastExcel. You can use the Maven `dependency:tree` command to view the dependency tree.
132+
- **A:** Common dependency conflicts include POI, ehcache, commons-io, etc. It is recommended to check the dependency tree in the project, ensure that the versions used are compatible with FastExcel. You can use the Maven `dependency:tree` command to view the dependency tree.
133133

134134
#### Performance Monitoring
135135
- **Q:** How to monitor the performance of FastExcel?
@@ -146,7 +146,7 @@ description: Frequently Asked Questions
146146
```java
147147
FastExcel.read(file, MultipleSheetsData.class, new MultipleSheetsListener()).doReadAll();
148148
```
149-
Alternatively, you can get information about all sheets before reading:
149+
Alternatively, you can get information on all sheets before reading:
150150
```java
151151
ExcelReader excelReader = FastExcel.read(file, MultipleSheetsData.class, multipleSheetsListener).build();
152152
List<ReadSheet> sheets = excelReader.excelExecutor().sheetList();
@@ -179,7 +179,7 @@ description: Frequently Asked Questions
179179

180180
#### Read CSV Files
181181
- **Q:** How to read CSV files and modify the delimiter?
182-
- **A:** You can modify the delimiter of a CSV file by setting `CsvFormat`. For example:
182+
- **A:** You can modify the delimiter of CSV files by setting `CsvFormat`. For example:
183183
```java
184184
String fileName = TestFileUtil.getPath() + "demo" + File.separator + "demo.csv";
185185
try (ExcelReader excelReader = FastExcel.read(fileName, DemoData.class, new DemoDataListener()).build()) {
@@ -194,7 +194,7 @@ description: Frequently Asked Questions
194194
```
195195

196196
#### Custom Read Listener
197-
- **Q:** How to customize a read listener?
197+
- **Q:** How to customize the read listener?
198198
- **A:** You can inherit the `AnalysisEventListener` class and implement your own logic. For example:
199199
```java
200200
public class CustomReadListener extends AnalysisEventListener<DemoData> {
@@ -224,7 +224,7 @@ description: Frequently Asked Questions
224224

225225
#### Set Header Style During Export
226226
- **Q:** How to set header style during export?
227-
- **A:** You can customize header style by implementing the `WriteHandler` interface. For example:
227+
- **A:** You can customize the header style by implementing the `WriteHandler` interface. For example:
228228
```java
229229
public class CustomHeadStyleWriteHandler extends AbstractHeadStyleWriteHandler {
230230
@Override
@@ -238,7 +238,7 @@ description: Frequently Asked Questions
238238
```
239239

240240
#### Set Cell Data Format During Export
241-
- **Q:** How to set the data format of a cell during export?
241+
- **Q:** How to set the data format of cells during export?
242242
- **A:** You can set the data format by using the `@ContentStyle` annotation on entity class properties. For example:
243243
```java
244244
@ExcelProperty("Amount")
@@ -248,7 +248,7 @@ description: Frequently Asked Questions
248248

249249
#### Merge Cells During Export
250250
- **Q:** How to merge cells during export?
251-
- **A:** You can customize cell merging logic by implementing the `WriteHandler` interface. For example:
251+
- **A:** You can customize the logic for merging cells by implementing the `WriteHandler` interface. For example:
252252
```java
253253
public class MergeCellWriteHandler implements WriteHandler {
254254
@Override
@@ -259,7 +259,7 @@ description: Frequently Asked Questions
259259
```
260260

261261
#### Set Font During Export
262-
- **Q:** How to set the font of a cell during export?
262+
- **Q:** How to set the font of cells during export?
263263
- **A:** You can set the font by creating a `Font` object and applying it to the `CellStyle`. For example:
264264
```java
265265
public class CustomFontWriteHandler extends AbstractCellStyleWriteHandler {
@@ -291,7 +291,7 @@ description: Frequently Asked Questions
291291
}
292292
```
293293

294-
#### Filter Data During Reading
294+
#### Data Filtering During Reading
295295
- **Q:** How to filter data during reading?
296296
- **A:** You can implement filtering logic in the `ReadListener`. For example:
297297
```java

0 commit comments

Comments
 (0)