Skip to content

Commit d966ff1

Browse files
committed
update web app config in docs
1 parent 26ea127 commit d966ff1

1 file changed

Lines changed: 37 additions & 26 deletions

File tree

docs/configure_web_app.md

Lines changed: 37 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -9,36 +9,36 @@ title: Configuring the Web Application
99

1010
# <a name="layout"></a>Layout of a PhiloLogic Web Application Instance
1111

12-
This database directory contains:
13-
14-
- The indexes and other data strutures
15-
- The web application, which includes server-side Python runtime functions and the AngularJS client application
16-
17-
Here is what the database directory looks like after a load:
12+
Each loaded database contains its own copy of the web application and data. Here is what the database directory looks like after a load:
1813

1914
<pre><code>
2015
database/
21-
├── app
22-
├── data
23-
│ ├── db.locals.py
24-
│ ├── frequencies
25-
│ ├── index
26-
│ ├── index.1
27-
│ ├── load_config.py
28-
│ ├── src
29-
│ ├── TEXT
30-
│ ├── toms.db
31-
│ └── web_config.cfg
32-
├── reports
33-
└── scripts
16+
├── app/ # Vue.js client application
17+
│ ├── src/
18+
│ │ └── assets/styles/
19+
│ │ └── theme.module.scss
20+
│ ├── dist/ # Built frontend (generated by npm run build)
21+
│ ├── appConfig.json
22+
│ ├── package.json
23+
│ └── vite.config.js
24+
├── data/
25+
│ ├── db.locals.py # Database-level settings
26+
│ ├── web_config.cfg # Web application configuration
27+
│ ├── load_config.py # Load-time configuration (read-only after load)
28+
│ ├── frequencies/ # Word frequency data
29+
│ ├── words.lmdb # Word index (LMDB)
30+
│ ├── toms.db # Metadata (SQLite)
31+
│ ├── TEXT/ # Source XML files
32+
│ └── hitlists/ # Cached query results
33+
├── custom_functions/ # User-defined Python functions
34+
└── favicon.ico
3435
</code></pre>
3536

36-
There are four distinct sections inside the application:
37+
There are three main sections:
3738

38-
- The `app/` directory: this contains the web client, and is organized according to functionality and shared components.
39-
- The `data/`directory contains all the indexes and SQLite tables needing for search and retrieval, as well as database and web configuration files.
40-
- The `reports/` directory, which contains the major search reports which fetch data from the database by interfacing with the core library, and then return a specialized results report as a JSON object. These reports include concordance, KWIC (Key Word In Context), collocation, and time series.
41-
- The `scripts/` directory, which contains standalone CGI scripts that are called directly from JavaScript code on the client side. These functions have a very specialized purpose, such as returning the total number of hits for any given query.
39+
- The `app/` directory contains the Vue.js web client. The `src/` subdirectory has the source code, and `dist/` contains the built production files served to browsers.
40+
- The `data/` directory contains all indexes, LMDB databases, SQLite tables, and configuration files needed for search and retrieval.
41+
- The `custom_functions/` directory allows you to override or extend the default server-side behavior with custom Python functions.
4242

4343
# <a name="ui"></a>Modifying the behavior of the Web Application
4444

@@ -58,8 +58,20 @@ Once access control has been turned on, PhiloLogic will check the `access_file`
5858
## <a name="changing-theme"></a>Changing the Web Application theme
5959
Changing the Web Application theme requires editing the `theme.module.scss` file which can be found in the database directory under `app/src/assets/styles/`.
6060

61-
The `theme.module.scss` file is a Sass stylesheet which makes use of global variables to define the main colors used in the web app. All you should need to do is edit `$header-color`, `$button-color`, `$button-color-active`, `$link-color`. Once you've edited the theme file, you will need to rebuild the web application. In order to do so, go to the `app/` directory and run the following command in the terminal:
61+
The `theme.module.scss` file is a Sass stylesheet which uses global variables to define the main colors used in the web app. The key variables are:
62+
63+
```scss
64+
$header-color: rgb(95, 2, 2); // Navigation bar background
65+
$button-color: rgb(173, 66, 66); // Primary buttons, form elements
66+
$button-color-active: rgba(160, 55, 55, 0.9); // Active/hover state
67+
$link-color: rgb(156, 60, 60); // Hyperlinks and text accents
68+
$passage-color: rgb(155, 65, 55); // Search result highlights
69+
$card-header-color: rgb(173, 66, 66); // Card and table headers
6270
```
71+
72+
Once you've edited the theme file, rebuild the web application by running the following command from the `app/` directory:
73+
74+
```bash
6375
npm run build
6476
```
6577

@@ -137,4 +149,3 @@ aggregation_config = [
137149
},
138150
]
139151
```
140-

0 commit comments

Comments
 (0)