craftcms / cms

Build bespoke content experiences with Craft.
https://craftcms.com
Other
3.22k stars 626 forks source link

[4.x]: Instructions Markdown Link #11377

Closed mattwardcc closed 2 years ago

mattwardcc commented 2 years ago

What happened?

Description

I'm having an issue with Markdown links in the instructions on a global. The system seems to be adding some sort of additional namespacing to the link.

Steps to reproduce

Expected behavior

Actual behavior

Instead, I'm getting the following link code: <a href="fields-/admin/seomatic/site/social/default">Social Media</a>. For some reason it's adding that leading fields- to the href? It was suggested on Discord that this could be some sort of namespacing issue.

Just as a note, I want this to be a relative URL so that it is environment agnostic. I'm not sure if this same thing happens with a full URL or in any of the other field layouts besides globals (Entries, Assets etc.)

Craft CMS version

4.0.3

PHP version

8.0.19

Operating system and version

macOS Catalina

Database type and version

MySQL 5.7.31

Image driver and version

GD 8.0.19

Installed plugins and versions

{
    "require": {
        "craftcms/cms": "4.0.3",
        "craftcms/redactor": "3.0.0",
        "doublesecretagency/craft-cpcss": "2.5.0",
        "nystudio107/craft-minify": "4.0.0-beta.2",
        "nystudio107/craft-seomatic": "4.0.0",
        "nystudio107/craft-typogrify": "4.0.0",
        "sebastianlenz/linkfield": "2.1.3-rc",
        "vaersaagod/matrixmate": "2.0.1",
        "verbb/navigation": "2.0.1",
        "verbb/super-table": "3.0.0-beta.4",
        "verbb/vizy": "2.0.1",
        "vlucas/phpdotenv": "^2.4.0"
    },
    "autoload": {
        "psr-4": {
            "modules\\ccfieldsmodule\\": "modules/ccfieldsmodule/src/",
            "modules\\cchelpersmodule\\": "modules/cchelpersmodule/src/",
            "modules\\ccapimodule\\": "modules/ccapimodule/src/"
        }
    },
    "config": {
        "sort-packages": true,
        "optimize-autoloader": true,
        "platform": {
            "php": "8.0.2"
        },
        "allow-plugins": {
            "craftcms/plugin-installer": true,
            "yiisoft/yii2-composer": true
        }
    },
    "scripts": {
        "post-root-package-install": [
            "@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
        ]
    }
}
brandonkelly commented 2 years ago

Thanks for pointing that out! Fixed for the next release.

brandonkelly commented 2 years ago

Craft 4.0.4 is out now with that fix.