From be4d2e9a22b75efca5c480ad0c5077d9813bbfc2 Mon Sep 17 00:00:00 2001 From: Elias Zeitfogel Date: Sun, 20 Dec 2015 20:34:12 +0100 Subject: [PATCH] Some proofreading and fixing from "Welcome" to "Templates" --- content/docs/api/db/record/pagination/contents.lr | 1 + content/docs/api/db/types/flow/contents.lr | 2 +- content/docs/content/alts/contents.lr | 2 +- content/docs/content/attachments/contents.lr | 8 ++++---- content/docs/content/contents.lr | 2 +- content/docs/content/urls/contents.lr | 10 +++++----- content/docs/installation/contents.lr | 2 +- content/docs/models/contents.lr | 4 ++-- content/docs/models/flow/contents.lr | 4 ++-- content/docs/project/file/contents.lr | 2 +- content/docs/project/structure/contents.lr | 14 +++++++------- content/docs/templates/contents.lr | 2 +- content/docs/templates/imageops/contents.lr | 2 +- content/docs/what/contents.lr | 4 ++-- 14 files changed, 30 insertions(+), 29 deletions(-) diff --git a/content/docs/api/db/record/pagination/contents.lr b/content/docs/api/db/record/pagination/contents.lr index b71d91ff..2376672d 100644 --- a/content/docs/api/db/record/pagination/contents.lr +++ b/content/docs/api/db/record/pagination/contents.lr @@ -22,6 +22,7 @@ The following attributes exist on the pagination object: | `next` | The record for the net page (might be `None`) | `total` | The total number of items across all pages | `pages` | The total number of pages +| `page` | The number of current page | `has_prev` | `True` if a previous page exists | `has_next` | `True` if a next page exists | `items` | The query that resolves to the children of the current page. diff --git a/content/docs/api/db/types/flow/contents.lr b/content/docs/api/db/types/flow/contents.lr index d4729b88..938f0c9d 100644 --- a/content/docs/api/db/types/flow/contents.lr +++ b/content/docs/api/db/types/flow/contents.lr @@ -74,5 +74,5 @@ or more complex: ``` To see how the actual blocks are rendered have a look at the main -[Flow Documentation :ref](../../content/flow/) which covers templating +[Flow Documentation :ref](../../../../content/flow/) which covers templating in detail. diff --git a/content/docs/content/alts/contents.lr b/content/docs/content/alts/contents.lr index fb1944f1..d878e0dc 100644 --- a/content/docs/content/alts/contents.lr +++ b/content/docs/content/alts/contents.lr @@ -12,7 +12,7 @@ or regions. ## Enabling Alternatives To enable alternatives you need to extend your [Project File -:ref](../../project/). For each alternative a new +:ref](../../project/file/). For each alternative a new section has to be added. It's important that one of the alternatives is marked as "primary" which informs the system which of the alternatives is the reference. diff --git a/content/docs/content/attachments/contents.lr b/content/docs/content/attachments/contents.lr index 6743fec7..98e163af 100644 --- a/content/docs/content/attachments/contents.lr +++ b/content/docs/content/attachments/contents.lr @@ -9,7 +9,7 @@ directly in the page folder and become available publicly. ## Attachment Types -For the most part Lektor does care much about what types your attachments +For the most part Lektor does not care much about what types your attachments are but it will specially handle some. In particular image formats supported by browsers have special support for automatic thumbnailing and accessing basic image data. @@ -33,10 +33,10 @@ extra extension: | sunset.jpeg | sunset.jpeg.lr | code.py | code.py.lr -Attachments can be [given a default model :ref](../../models/#attachments) or -a model can be explicitly given in the content file with the `_model` field. +Attachments can be [given a default model :ref](../../models/attachments/) or +a model can be explicitly given in the metadata content file with the `_model` field. -Here a basic example: +Here is a basic example: ``` _model: image diff --git a/content/docs/content/contents.lr b/content/docs/content/contents.lr index 7c2e564f..f032ad14 100644 --- a/content/docs/content/contents.lr +++ b/content/docs/content/contents.lr @@ -46,7 +46,7 @@ the rendered end result will be at `/portfolio/project-a/`. ## Page, Model and Template Each page is associated with a model and a template. Each page needs to have -a model that defines with fields exist. The template by default matches the +a model that defines which fields exist. The template by default matches the model name but it can be overridden on a per-page basis. So how is the model selected? Either expicitly in the `contents.lr` file diff --git a/content/docs/content/urls/contents.lr b/content/docs/content/urls/contents.lr index 613b57f6..15665674 100644 --- a/content/docs/content/urls/contents.lr +++ b/content/docs/content/urls/contents.lr @@ -21,9 +21,9 @@ all parents. Can a slug contain slashes? Yes indeed it can. A slug is free to contain any slashes if it wants and they will be handled just as you expect. So it's perfectly valid for a page to have `2015/5/demo` as slug. What's not possible -is for a page to pretent that it belongs to a different parent. The parent -paths are always added to it. So once the page is below `/foo` the URL path -will always begin with the URL path of the page `foo`. +is for a page to pretend that it belongs to a different parent. The parent +paths are always added to it. So once a page has a parent page `/foo` +its URL path will always begin with the URL path of the page `foo`. ## Slug Customization @@ -44,7 +44,7 @@ The second option is to use the `_slug` system field. This field is available for all models automatically and overrides the slug explicitly. This is particularly useful to force a slug that could not be represented on the file system (for instance because it should contain a slash) or because you want -to change the slug for a different [Alternative :ref](../alternatives/). As +to change the slug for a different [Alternative :ref](../alts/). As an example a page translated to German might want to translate the slug as well. ### Implied Slug Configuration @@ -103,7 +103,7 @@ You can pick the default for URL generation in the project configuration. For more information read about the [Project Configuration :ref](../../project/file/#[project]). -The default of `relative` a realtive URL style means that you can deploy a +The default of `relative`, a relative URL style, means that you can deploy a website to a sub folder without any configuration, however most likely custom 404 pages will fail to find the needed assets. Fully canonical URLs are not recommended as default style. diff --git a/content/docs/installation/contents.lr b/content/docs/installation/contents.lr index 2173db7f..5a7de139 100644 --- a/content/docs/installation/contents.lr +++ b/content/docs/installation/contents.lr @@ -26,7 +26,7 @@ and then click on *Lektor ➤ Install Shell Command*. If you do not want to install the desktop app you can just install the command line executable. This one runs on more operating systems (OSX, Linux and -Windows) but that installation is a bit more involved. +Windows) but the installation is a bit more involved. You need to make sure you have the following software installed on your computer: diff --git a/content/docs/models/contents.lr b/content/docs/models/contents.lr index afa1ae47..16a6e0e6 100644 --- a/content/docs/models/contents.lr +++ b/content/docs/models/contents.lr @@ -48,7 +48,7 @@ panel. ## Fields Fields for models are ordered in the UI in the order they appear in the model. -Most options in the field are specific to the type that is selectd, but some +Most options in the field are specific to the type that is selected, but some are the same for all of them. Fields not only define the behavior of the data (for instance strings and @@ -76,7 +76,7 @@ extensively in the [types documentation :ref](../api/db/types/). ## Model Options -Models have the following options that can cutomize the model itself: +Models have the following options that can customize the model itself: - `name`: the name of the model itself. Usually a more capitalized form of the filename which is the ID of the model. diff --git a/content/docs/models/flow/contents.lr b/content/docs/models/flow/contents.lr index e7f78330..f0605a88 100644 --- a/content/docs/models/flow/contents.lr +++ b/content/docs/models/flow/contents.lr @@ -4,9 +4,9 @@ summary: Explains how to model flow blocks. --- body: -To use [Flow :ref](../../flow/) you need to define flow block models. +To use [Flow :ref](../../content/flow/) you need to define flow block models. If you are not familiar with Flow yet, you should read the [Introduction -Documentation](../../flow/) to Flow first. +Documentation](../../content/flow/) to Flow first. ## Defining Models diff --git a/content/docs/project/file/contents.lr b/content/docs/project/file/contents.lr index 5ce84317..8c855f61 100644 --- a/content/docs/project/file/contents.lr +++ b/content/docs/project/file/contents.lr @@ -17,7 +17,7 @@ name = My Fancy Project The name of the file can be arbitrary but must have the `.lektorproject` extension or Lektor will not be able to find it. When Lektor looks for a project it looks upwards from the current folder until it finds a single -file with the `.lektorproject` extension then that's the root of the project. +file with the `.lektorproject` extension and that's then the root of the project. ## Config Sections diff --git a/content/docs/project/structure/contents.lr b/content/docs/project/structure/contents.lr index 01d90777..4b139f9c 100644 --- a/content/docs/project/structure/contents.lr +++ b/content/docs/project/structure/contents.lr @@ -54,7 +54,7 @@ content/ thumbnail.png ``` -The content folder is explained in detail in [Content :ref](../content/). +The content folder is explained in detail in [Content :ref](../../content/). ### `models/` @@ -62,7 +62,7 @@ This is the bread and butter of what makes Lektor powerful. The models define exactly how the data from the content folder should be processed. The `models` folder contains a list of INI files that each correspond to a single model. -For more information about this refer to the [Data Modelling :ref](../models/) +For more information about this refer to the [Data Modelling :ref](../../models/) documentation. ### `templates/` @@ -80,8 +80,8 @@ files they will appear as such in the final output. ### `flowblocks/` The `flowblocks` folder contains models for blocks that are used by the -[Flow System :ref](../content/flow/). Flow blocks split part of a page into -smaller pieces that can be individually designed. They work similar to models +[Flow System :ref](../../content/flow/). Flow blocks split a part of a page into +smaller pieces so that can be individually designed. They work similar to models but are contained within a field of a model. ### `packages/` @@ -96,8 +96,8 @@ files in there are named `.ini`. ### `databags/` -Lektor also supports [Data Bags :ref](../content/databags/) which go into a +Lektor also supports [Data Bags :ref](../../content/databags/) which go into a folder named `databags/`. These are files with some general information that can be accessed from templates. For instance you could store menus and -navigations there, API keys and much more. Just information you want to -access from different places and maybe not keep in templates directly. +navigations there, API keys and much more. This is generally just information +you want to access from different places and maybe not keep in templates directly. diff --git a/content/docs/templates/contents.lr b/content/docs/templates/contents.lr index a52d84fc..190837c0 100644 --- a/content/docs/templates/contents.lr +++ b/content/docs/templates/contents.lr @@ -38,7 +38,7 @@ evaluated in but the following are always available: ## The First Template So let's dive in making our first template. In case you went through the -[Quickstart :ref](../quickstart/) which should give you an example model +[Quickstart :ref](../quickstart/) you should already have an example model to work with called `page`, otherwise just add one with the format shown in the [Data Modelling Documentation :ref](../models/). diff --git a/content/docs/templates/imageops/contents.lr b/content/docs/templates/imageops/contents.lr index 5fdd326f..3a29574a 100644 --- a/content/docs/templates/imageops/contents.lr +++ b/content/docs/templates/imageops/contents.lr @@ -60,7 +60,7 @@ Here an example that shows the camera information: While browsers are reasonably good at downscaling images themselves, you still need to transmit the entire image. When you want smaller images it often makes sense to generate thumbnails automatically. In Lektor each -image provides the [thumbnail :ref](../../../api/record/thumbnail/) method. +image provides the [thumbnail :ref](../../api/db/record/thumbnail/) method. It accepts the width and height of the target image. If the height is not provided it will be scaled proportionally. The return value can be converted diff --git a/content/docs/what/contents.lr b/content/docs/what/contents.lr index 596400e1..bf61628a 100644 --- a/content/docs/what/contents.lr +++ b/content/docs/what/contents.lr @@ -6,13 +6,13 @@ sort_key: 20 --- body: -When it comes to creating websites, there ludicrous amount of tools available. +When it comes to creating websites, there is a ludicrous amount of tools available. They range from full blown content management solutions like Drupal over desktop solutions like Google Web Designer to Cloud Hosted Website solutions like WIX to more programmer focused approaches like Jekyll which generate websites out of templates and markdown files. -*Lektor is different than any of these.* +*Lektor is different from any of these.* ## Lektor is Static