Skip to content

Commit

Permalink
Merge branch 'craft-4' of https://github.com/verbb/hyper into craft-5
Browse files Browse the repository at this point in the history
# Conflicts:
#	CHANGELOG.md
#	composer.json
#	src/base/Link.php
#	src/console/controllers/MigrateController.php
#	src/console/controllers/TypedLinkLegacyController.php
#	src/controllers/MigrationsController.php
#	src/fields/HyperField.php
#	src/migrations/MigrateTypedLinkContent.php
#	src/templates/settings/migrate/link.html
#	src/templates/settings/migrate/linkit.html
#	src/templates/settings/migrate/typed-link.html
  • Loading branch information
engram-design committed Jul 21, 2024
2 parents 862f831 + d399930 commit 719cd01
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 4 deletions.
17 changes: 17 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,23 @@
### Removed
- Remove migrations for other plugin (not supported in Craft 5).

## 1.2.0 - 2024-07-21

### Added
- Add `Link::linkUri`.
- Add “Create backup” checkbox for migrations.
- Add `create-backup` console command option for migrations.
- Add missing descriptions for console commands.

### Changed
- Change element-based links properly checking if their linked-to element is “empty”. For example, linking to a disabled element will now make `isEmpty` return true.
- Improve GraphQL Schema generation performance. (thanks @markhuot).
- Handle migration of anchor-only URLs for Typed Link fields.

### Fixed
- Fix Typed Link migration for Site link types.
- Fix parsing emoji's in link URLs. (thanks @sfsmfc).

## 1.1.32 - 2024-06-15

### Added
Expand Down
9 changes: 5 additions & 4 deletions docs/developers/link.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,15 @@ The Link represents the actual value of the field, as you'd want to output in yo

Attribute | Description
--- | ---
`type` | Returns the link type class name chosen for the link.
`linkType` | Returns the link type chosen for the link.
`type` | Returns the link type class name chosen for the link. e.g. `verbb\hyper\links\Entry`.
`linkType` | Returns the [link type](docs:developers/link-type) object chosen for the link.
`url` | The value used for the `href` for the link. Supports .env variables and aliases, and combines any prefix or suffix.
`text` | The custom text for the label of the link. If an element link type, the title of the element will be used automatically.
`text` | The derived text for the label of the link. If an element link type, the title of the element will be used automatically.
`target` | Returns `_blank` if the link should open in a new window.
`newWindow` | Whether the link should open in a new window.
`linkUrl` | The link URL. Supports .env variables and aliases.
`linkUrl` | The link URL. Supports `.env` variables and aliases.
`linkValue` | The value of the link. This will vary depending on the link type.
`linkText` | The custom text for the link. e.g. `Read more`.
`ariaLabel` | The value for the `aria-label` attribute for the link.
`urlSuffix` | The suffix value to append to the URL.
`linkTitle` | The value for the `title` attribute for the link.
Expand Down

0 comments on commit 719cd01

Please sign in to comment.